Rewrite in Ngnix

xxx nginx-forum at nginx.us
Sat Apr 21 06:11:27 UTC 2012


Hi,
How convert to httacces from apache to nginx

My file htaccess is:

#Options FollowSymLinks

RewriteEngine on

RewriteRule ^vardata/(.*).php$ [R=404,L]
RewriteRule ^([a-zA-Z0-9_-]+).html$ index.php?op=$1
RewriteRule ^([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+).html$
index.php?op=$1&do=$2
RewriteRule ^([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+).html$
index.php?op=$1&do=$2&id=$3
RewriteRule
^([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+).html$
index.php?op=$1&do=$2&id=$3&qs=$4
RewriteRule
^([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+).html$
index.php?op=$1&do=$2&id=$3&qs=$4&ne=$5
RewriteRule
^([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+).html$
index.php?op=$1&do=$2&id=$3&qs=$4&ne=$5&nr=$6
RewriteRule
^([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+).html$
index.php?op=$1&do=$2&id=$3&qs=$4&ne=$5&nr=$6&ha=$7
RewriteRule
^([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+),([a-zA-Z0-9_-]+).html$
index.php?op=$1&do=$2&id=$3&qs=$4&ne=$5&nr=$6&ha=$7&hs=$8 [L] 


HELP Me!

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,225583,225583#msg-225583



More information about the nginx mailing list