A5下载 - 努力做内容最丰富最安全的下载站!

A5站长下载站

当前位置:A5下载 > 源码技巧 > 帝国cms > 帝国7.0伪静态Apache的Rewrite设置方法

帝国7.0伪静态Apache的Rewrite设置方法

时间:2015-06-04 10:06作者:sa人气:42

这篇文章主要为大家介绍了帝国7.0伪静态Apache的Rewrite设置方法,需要的朋友可以参考下

代码如下:

# 将 RewriteEngine 模式打开

RewriteEngine On

#信息内容页:showinfo-[!--classid--]-[!--id--]-[!--page--].html

RewriteCond %{QUERY_STRING} ^(.*)$

 

RewriteRule ^showinfo-(.+?)-(.+?)-(.+?).html$ /e/action/ShowInfo.php?classid=$1&id=$2&page=$3</p>

<p>#信息列表:listinfo-[!--classid--]-[!--page--].html

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^listinfo-(.+?)-(.+?).html$ /e/action/ListInfo/index.php?classid=$1&page=$2</p> <p>#标题分类列表页:infotype-[!--ttid--]-[!--page--].html

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^infotype-(.+?)-(.+?).html$ /e/action/InfoType/index.php?ttid=$1&page=$2</p> <p>#TAGS信息列表页:tags-[!--tagname--]-[!--page--].html

RewriteCond %{QUERY_STRING} ^(.*)$

RewriteRule ^tags-(.+?)-(.+?).html$ /e/tags/index.php?tagname=$1&page=$2

以上就是默认的Rewrite规则设置方法。

 

标签帝国,7.0,静态,Apache,Rewrite,设置,方法

相关下载

查看所有评论+

网友评论

网友
您的评论需要经过审核才能显示

公众号