Rewriting all requests to index.php

Reinis Rozitis r at
Tue Jul 13 12:29:34 MSD 2010

You can use also the try_files ( ) approach:

location / {
    try_files $uri $uri/ /index.php?$args;

This way you can also have normal directories and static files and nginx 
will check first if they exist and if not then use the /index.php in the 
root folder.


More information about the nginx mailing list