Welcome Guest, Not a member yet? Register   Sign In
Routes- Today i died
#7

(09-18-2019, 05:50 PM)ciadmin Wrote: @Yuriy The document root should be "/var/www/html/example.com/public", without the index.php. I can't remember if it ahs a trailing slash or not.

This is exactly what the CI4 installation directions say, for running a CI4 app.

Hopefully this will revive @5flex too Smile
Thanks! I agree now because with index.php don't work style and js.
So I have style files in public/css and js in public/js and svg in public/svg.

Latest version:

<VirtualHost *:80>
    ServerAdmin [email protected]
    ServerName server.part2
    ServerAlias myDomen
    DocumentRoot /var/www/html/server.part2/public/

    RewriteEngine On
    RewriteCond %{REQUEST_URI} !/index\.php/
    RewriteCond %{REQUEST_URI} !/css*
    RewriteCond %{REQUEST_URI} !/js*
    RewriteCond %{REQUEST_URI} !/svg*
    RewriteRule ^/(.*) /index.php/$1 [L]

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>

I'm sure you can write better but it works!
Reply


Messages In This Thread
Routes- Today i died - by 5flex - 09-18-2019, 07:13 AM
RE: Routes- Today i died - by ciadmin - 09-18-2019, 07:43 AM
RE: Routes- Today i died - by includebeer - 09-18-2019, 11:21 AM
RE: Routes- Today i died - by Yuriy - 09-18-2019, 12:58 PM
RE: Routes- Today i died - by unromantic - 09-18-2019, 03:09 PM
RE: Routes- Today i died - by ciadmin - 09-18-2019, 05:50 PM
RE: Routes- Today i died - by Yuriy - 09-19-2019, 01:12 AM



Theme © iAndrew 2016 - Forum software by © MyBB