-
16#
zyypp
-
2009-10-12 22:39:33
把你的那个 改了下 中间的红色的 为你的rewrite 我不知道 对不 所以 也没改
总体 就是这个结构了
server
{
listen 80;
server_name 要绑定的域名;
root 网站目录的绝对路径;
location / {
rewrite ^/archiver/((fid|tid)-[\w\-]+\.html)$ /archiver/index.php?$1 last;
rewrite ^/forum-([0-9]+)-([0-9]+)\.html$ /forumdisplay.php?fid=$1&page=$2 last;
rewrite ^/thread-([0-9]+)-([0-9]+)-([0-9]+)\.html$ /viewthread.php?tid=$1&extra=page%3D$3&page=$2 last;
rewrite ^/space-(username|uid)-(.+)\.html$ /space.php?$1=$2 last;
rewrite ^/tag-(.+)\.html$ /tag.php?name=$1 last;
break;
if ($host != 'moltown.com/my' ) {
rewrite ^/(.*)$ http://moltown.com/my/$1 permanent;
}
rewrite ^/(post|record|sort|author|page)-([0-9]+)\.html$ /index.php?$1=$2;
rewrite ^/tag-(.+)\.html$ /index.php?tag=$1;
}
location /status {
stub_status on;
access_log off;
}
}