apache .htaccess rewrite

Payam Chychi pchychi at gmail.com
Thu Apr 1 10:20:02 MSD 2010

hey Guys,

I cant seem to figure out why I cant properly convert this from apache 
to nginx, any help would be appreciated... ive tried a dozen times but 
it just will not function as expected.


Options +FollowSymLinks
RewriteEngine On
RewriteBase /

# URL PATTERN for sitetown

# Main -> Category
# http://www.site.com/category-name/
RewriteRule ^([A-Za-z0-9\-]+)/([0-9]+).html$ 
results.php?category_id=$2&category=$1 [L]

#New and Improved witht the .html support!
RewriteRule ^([A-Za-z0-9\-]+)/([0-9]+)/([0-9]+)/([A-Za-z0-9\-]+).html$ 
details.php?pid=$2&pkey=$3&category=$1&title=$4 [L]

RewriteRule ^(.*).html$ $1.php

thanks in advance

More information about the nginx mailing list