Apache url rewrite to Nginx
- by Kaloyan
i work on a little php platform and my server is nginx.
The first version of this php site was developed for Apache server.
I need to upgrade the site and to migrate it to nginx server.
The problem is url rewriting. I have this simple url rewrite rules in my Apache server:
RewriteEngine On
RewriteBase /simple-php/
RewriteCond %{REQUEST_FILENAME} !-d [NC]
RewriteCond %{REQUEST_FILENAME} !-f [NC]
RewriteRule ^(.*)$ viewpost.php?id=$1 [QSA,L]
I can't "translate" this to nginx rewrite syntax.
Can anybody help me?
P.S. I can read both documentations, but i have not this time, just need fast solution.
Thanks!