请教nginx伪静态弄来弄去一直404
前天装的lnmp一键包,做了几个站,基本都是动态的,今天装了个站,开启伪静态,除了首页,其他页面都是404404 Not Foundnginx/0.7.67
我说下我的步骤,高手们指点下哪里错了,我看了网上的一些教程首先我用sftp进入/usr/local/nginx/conf/vhost/ 目录下,找到我的 域名.conf文件,下载-编辑
http://img181.poco.cn/mypoco/myphoto/20110331/18/5658212720110331184613048.jpg
打开域名.conf文件,该域名调用的伪静态规则文件是fcgi.conf于是下载fcgi.conf 文件编辑 在下面添加我的伪静态规则
location / {
rewrite "^(.*)sort_(+)_(+).html$" $1sort.php?sortid=$2&page=$3 last;rewrite "^(.*)over_(+).html$" $1over.php?page=$2 last;rewrite "^(.*)top_(.*)_(+).html$" $1top.php?topid=$2&page=$3 last;rewrite "^(.*)topover_(.*)_(+).html$" $1topover.php?topid=$2&page=$3 last;rewrite "^(.*)book_(+).html$" $1book.php?bookid=$2 last;rewrite "^(.*)down_(.*)_(+).html$" $1down.php?bookid=$3&type=$2 last;rewrite "^(.*)readend_(+).html$" $1readend.php?bookid=$2 last;rewrite "^(.*)read_(+)_(+).html$" $1read.php?cutid=$2&bookid=$3 last;rewrite "^(.*)chapter_(+)_(+)_(+).html$" $1chapter.php?cutid=$2&bookid=$3&chapterid=$4 last;};
http://img181.poco.cn/mypoco/myphoto/20110331/18/5658212720110331185114020.jpg
添加后上传 /usr/local/nginx/sbin/nginx -s reload ssh输入指令,重启nginx 打开网站,伪静态页面仍然404
高手指点下!!
回复 1# 的帖子
伪静态添加问题请阅读http://lnmp.org/install.html
回复 2# 的帖子
悲剧了,我是添加域名后添加伪静态的
页:
[1]