Created
May 9, 2013 14:40
-
-
Save necenzurat/5547867 to your computer and use it in GitHub Desktop.
pt nginx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rewrite ^/product/(.*).html$$ /products.php?q=$1&rewrite=1 last; | |
rewrite ^/review/(.*).html$ /reviews.php?q=$1&rewrite=1 last; | |
#category | |
location = /category/ { | |
rewrite ^(.*)$ /categories.php; | |
} | |
location = /category { | |
rewrite ^/category/(.*)/$ search.php?q=category:$1:&rewrite=1 last; | |
rewrite ^/category/(.*)/(.*).html$ search.php?q=category:$1:&page=$2&rewrite=1 last; | |
} | |
#merchant | |
location = /merchant/ { | |
rewrite ^(.*)$ /merchants.php; | |
} | |
location /merchant { | |
rewrite ^/merchant/(.*)/$ /search.php?q=merchant:$1:&rewrite=1 last; | |
rewrite ^/merchant/(.*)/(.*).html$ /search.php?q=merchant:$1:&page=$2&rewrite=1 last; | |
} | |
#brand | |
location = /brand/ { | |
rewrite ^(.*)$ /brands.php; | |
} | |
location /brand { | |
rewrite ^/brand/(.*)/$ /search.php?q=brand:$1:&rewrite=1 last; | |
rewrite ^/brand/(.*)/(.*).html$ /search.php?q=brand:$1:&page=$2&rewrite=1 last; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment