Skip to content

Instantly share code, notes, and snippets.

@kamil161g
Created June 25, 2018 17:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kamil161g/d8a88abbcdc81a468ddc0b08f70d68ba to your computer and use it in GitHub Desktop.
Save kamil161g/d8a88abbcdc81a468ddc0b08f70d68ba to your computer and use it in GitHub Desktop.
<IfModule mod_rewrite.c>
Options +FollowSymlinks
RewriteEngine On
DirectoryIndex index.php
# Explicitly disable rewriting for front controllers
RewriteRule ^/web/app_dev.php - [L]
RewriteRule ^/web/app.php - [L]
# Fix the bundles folder
RewriteRule ^bundles/(.*)$ /web/bundles/$1 [QSA,L]
# Fix the assets folder
RewriteRule ^assets/(.*)$ /web/assets/$1 [QSA,L]
RewriteCond %{REQUEST_FILENAME} !-f
# Change below before deploying to production
#RewriteRule ^(.*)$ /web/app.php [QSA,L]
RewriteRule ^(.*)$ /web/app_dev.php [QSA,L]
</IfModule>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment