Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- server {
- listen 80;
- server_name xxxxxx;
- location ~ /\.ht {
- deny all;
- }
- location ~ /\.svn {
- deny all;
- }
- location /fg152 {
- root /home/sites/domain/;
- index index.php;
- try_files $uri $uri/ /fg152/index.php;
- }
- location / {
- root /home/sites/domain/;
- index index.php index.html index.htm;
- # PHPBB SEO REWRITE RULES - ADVANCED
- # AUTHOR : dcz www.phpbb-seo.com
- # STARTED : 01/2006
- rewrite ^/(forum|[a-z0-9_-]*-f)([0-9]+)/?(page([0-9]+)\.html)?$ /viewforum.php?f=$2&start=$4 last;
- rewrite ^/(forum|[a-z0-9_-]*-f)([0-9]+)/(topic|[a-z0-9_-]*-t)([0-9]+)(-([0-9]+))?\.html$
- /viewtopic.php?f=$2&t=$4&start=$6 last;
- rewrite ^/([a-z0-9_-]*)/?(topic|[a-z0-9_-]*-t)([0-9]+)(-([0-9]+))?\.html$ /viewtopic.php?forum_uri=$1&t=$3&start=$5 last;
- rewrite ^/resources/[a-z0-9_-]+/(thumb/)?([0-9]+)$ /download/file.php?id=$2&t=$1 last;
- rewrite ^/member/([^/]+)/?$ /memberlist.php?mode=viewprofile&un=$1 last;
- rewrite ^/member/([^/]+)/(topics|posts)/?(page([0-9]+)\.html)?$ /search.php?author=$1&sr=$2&start=$4 last;
- rewrite ^/(group|[a-z0-9_-]*-g)([0-9]+)(-([0-9]+))?\.html$ /memberlist.php?mode=group&g=$2&start=$4 last;
- rewrite ^/post([0-9]+)\.html$ /viewtopic.php?p=$1 last;
- rewrite ^/active-topics(-([0-9]+))?\.html$ /search.php?search_id=active_topics&start=$2&sr=topics last;
- rewrite ^/unanswered(-([0-9]+))?\.html$ /search.php?search_id=unanswered&start=$2&sr=topics last;
- rewrite ^/newposts(-([0-9]+))?\.html$ /search.php?search_id=newposts&start=$2&sr=topics last;
- rewrite ^/unreadposts(-([0-9]+))?\.html$ /search.php?search_id=unreadposts&start=$2 last;
- rewrite ^/the-team\.html$ /memberlist.php?mode=leaders last;
- rewrite ^/([a-z0-9_-]+)/?(page([0-9]+)\.html)?$ /viewforum.php?forum_uri=$1&start=$3 last;
- rewrite ^/.+/(style\.php|ucp\.php|mcp\.php|faq\.php|download/file.php)$ /$1 last;
- rewrite ^/.+/(styles/.*|images/.*)/$ /$1last;
- if (!-e $request_filename) {
- rewrite ^/([a-z0-9_/-]+)/?(page([0-9]+)\.html)?$ /viewforum.php?forum_uri=$1&start=$3 last;
- break;
- }
- # END PHPBB PAGES
- }
- location ~ \.php {
- root /home/sites/domain/;
- fastcgi_split_path_info ^(.+\.php)(/.+)$;
- # A handy function that became available in 0.7.31 that breaks down
- # The path information based on the provided regex expression
- # This is handy for requests such as file.php/some/paths/here/
- fastcgi_param PATH_INFO $fastcgi_path_info;
- fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;
- fastcgi_param QUERY_STRING $query_string;
- fastcgi_param REQUEST_METHOD $request_method;
- fastcgi_param CONTENT_TYPE $content_type;
- fastcgi_param CONTENT_LENGTH $content_length;
- fastcgi_param SCRIPT_NAME $fastcgi_script_name;
- fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
- fastcgi_param REQUEST_URI $request_uri;
- fastcgi_param DOCUMENT_URI $document_uri;
- fastcgi_param DOCUMENT_ROOT $document_root;
- fastcgi_param SERVER_PROTOCOL $server_protocol;
- fastcgi_param GATEWAY_INTERFACE CGI/1.1;
- fastcgi_param SERVER_SOFTWARE nginx;
- fastcgi_param REMOTE_ADDR $remote_addr;
- fastcgi_param REMOTE_PORT $remote_port;
- fastcgi_param SERVER_ADDR $server_addr;
- fastcgi_param SERVER_PORT $server_port;
- fastcgi_param SERVER_NAME $server_name;
- fastcgi_pass unix:/etc/phpcgi/php-cgi.socket;
- fastcgi_index index.php;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement