VPS侦探论坛

 找回密码
 注册
查看: 7164|回复: 3

高手们给看一下伪静态规则,实在无奈了。

[复制链接]
发表于 2011-7-17 19:47:47 | 显示全部楼层 |阅读模式

这是APACHE下的,正常使用的。
RewriteEngine on
RewriteRule ^[a-zA-Z]+\/[a-zA-Z]+_([0-9]+_*[0-9]*)\.html$ art.php\?id=$1
RewriteRule ^hot\/([0-9]+)\.html$ like.php\?id=$1
RewriteRule ^[a-zA-Z]+\/[a-zA-Z]+\/([0-9]+)\.html$ topic.php\?id=$1
RewriteRule ^single/([a-zA-Z]+_*[0-9]*).html$ single.php\?f=$1
RewriteRule ^([a-zA-Z]+_*[0-9]*)\.html$ type.php\?id=$1
RewriteRule ^[a-zA-Z]+\/[a-zA-Z]+([0-9]+_*[0-9]*)\.html$ topic_list.php\?id=$1

我用军哥提供的转换成
rewrite ^/[a-zA-Z]+\/[a-zA-Z]+_([0-9]+_*[0-9]*)\.html$ /art.php\?id=$1;
        rewrite ^/hot\/([0-9]+)\.html$ /like.php\?id=$1;
        rewrite ^/[a-zA-Z]+\/[a-zA-Z]+\/([0-9]+)\.html$ /topic.php\?id=$1;
        rewrite ^/single/([a-zA-Z]+_*[0-9]*).html$ /single.php\?f=$1;
        rewrite ^/([a-zA-Z]+_*[0-9]*)\.html$ /type.php\?id=$1;
        rewrite ^/[a-zA-Z]+\/[a-zA-Z]+([0-9]+_*[0-9]*)\.html$ /topic_list.php\?id=$1;

结果是404,实在没办法了
高手帮看看规则有问题吗?
美国VPS推荐: 遨游主机LinodeLOCVPS主机云搬瓦工80VPSVultr美国VPS主机中国VPS推荐: 阿里云腾讯云。LNMP付费服务(代装/问题排查)QQ 503228080
发表于 2011-7-17 20:43:55 | 显示全部楼层


可能是转换后的伪静态有问题
Linux下Nginx+MySQL+PHP自动安装工具:https://lnmp.org
发表于 2011-7-21 12:50:25 | 显示全部楼层

看不不懂,帮忙顶下!
美国VPS推荐: 遨游主机LinodeLOCVPS主机云搬瓦工80VPSVultr美国VPS主机中国VPS推荐: 阿里云腾讯云。LNMP付费服务(代装/问题排查)QQ 503228080
发表于 2011-7-21 13:06:37 | 显示全部楼层
Linux下Nginx+MySQL+PHP自动安装工具:https://lnmp.org
您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|Archiver|VPS侦探 ( 鲁ICP备16040043号-1 )

GMT+8, 2024-9-20 23:44 , Processed in 0.025859 second(s), 16 queries .

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

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