Created
August 11, 2014 04:37
-
-
Save shadowhand/1fa9647a7c3d0379f42e to your computer and use it in GitHub Desktop.
nginx configuration for using a single file as the front controller
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
... | |
location / { | |
try_files $uri $uri/ @missing; | |
} | |
# Rewrite 404s back to PHP | |
# | |
location @missing { | |
rewrite ^ /index.php last; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment