location / { try_files $uri /index.php$uri; if (!-e $request_filename) { rewrite ^/(.*)$ /index.php?s=$1 last; break; } }