容器技术交流

 找回密码
 立即注册
查看: 2988|回复: 6

FAMP5.1.0 Nginx重写规则 一直找不到网页

[复制链接]
发表于 2009-6-3 21:12:28 | 显示全部楼层 |阅读模式
错了吗
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;
 楼主| 发表于 2009-6-3 21:20:28 | 显示全部楼层
http://www.chinazeus.com/read.php?tid=10

Discuz!的重定向规则:

if (!-f $request_filename) {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;}
 楼主| 发表于 2009-6-3 21:25:16 | 显示全部楼层
也是找不到网页 有问题
发表于 2009-6-3 21:29:41 | 显示全部楼层
 楼主| 发表于 2009-6-3 21:34:20 | 显示全部楼层

也是一直闪找 找不到网页 该怎处理 谢谢

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;
发表于 2009-6-3 21:37:48 | 显示全部楼层
这个吗,个人认为还是用apache吧,
htaccess很好用
 楼主| 发表于 2009-6-4 11:27:18 | 显示全部楼层

換Apache 可以用 為什麼Nginx重写规则 一直找不到网页

99我 .........................................
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

手机版|小黑屋|Archiver|URLOS ( 粤ICP备18087780号 )

GMT+8, 2024-5-15 11:03 , Processed in 0.031321 second(s), 18 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表