暂时只有APACHE IIS6 IIS7的规则,其他规则自行对照修改即可。不是很严谨,自己可以往严谨中修改:仅供参考!
apache下的.htaccess:
RewriteEngine OnErrordocument 404 /404.HTMLRewritebase /#信息列表RewriteCond %{query_STRING} ^(.*)$RewriteRule ^Listinfo-(.+?)-(.+?).HTML$ /e/action/ListInfo/index.PHP?classID=&page=#信息内容页RewriteCond %{query_STRING} ^(.*)$RewriteRule ^showinfo-(.+?)-(.+?)-(.+?).HTML$ /e/action/ShowInfo.PHP?classID=&ID=&page=#标题分类列表页RewriteCond %{query_STRING} ^(.*)$RewriteRule ^infotype-(.+?)-(.+?).HTML$ /e/action/InfoType/index.PHP?ttID=&page=#Tags信息列表页RewriteCond %{query_STRING} ^(.*)$RewriteRule ^Tags-(.+?)-(.+?).HTML$ /e/Tags/index.PHP?tagname=&page=#评论列表页RewriteCond %{query_STRING} ^(.*)$RewriteRule ^comment-(.+?)-(.+?)-(.+?)-(.+?)-(.+?)-(.+?).HTML$ /e/pl/index.PHP?doaction=&classID=&ID=&page=&myorder=&tempID=
IIS6下的httpd.ini:
[ISAPI_Rewrite]# 3600 = 1 hourCacheClockRate 3600Repeatlimit 32#信息列表RewriteRule ^(.*)Listinfo-(.+?)-(.+?).HTML$ /e/action/ListInfo/index.PHP?classID=&page=#信息内容页RewriteRule ^(.*)showinfo-(.+?)-(.+?)-(.+?).HTML$ /e/action/ShowInfo.PHP?classID=&ID=&page=#标题分类列表页RewriteRule ^(.*)infotype-(.+?)-(.+?).HTML$ /e/action/InfoType/index.PHP?ttID=&page=#Tags信息列表页RewriteRule ^(.*)Tags-(.+?)-(.+?).HTML$ /e/Tags/index.PHP?tagname=&page=#评论列表页RewriteRule ^(.*)comment-(.+?)-(.+?)-(.+?)-(.+?)-(.+?)-(.+?).HTML$ /e/pl/index.PHP?doaction=&classID=&ID=&page=&myorder=&tempID=#搜索伪静态
IIS7下的web.config:
<?xml version="1.0" enCoding="UTF-8"?><configuration><system.webServer><!--帝国7.2默认规则 IIS7的rule name不能重复相同--><rewrite><rules><rule name="Listinfo"><match url="^(.*/)*Listinfo-(.+?)-(.+?).HTML?*(.*)$" /><action type="Rewrite" url="{R:1}/e/action/ListInfo/index.PHP?classID={R:2}&page={R:3}" /></rule><rule name="showinfo"><match url="^(.*/)*showinfo-(.+?)-(.+?)-(.+?).HTML?*(.*)$" /><action type="Rewrite" url="{R:1}/e/action/ShowInfo.PHP?classID={R:2}&ID={R:3}&page={R:4}" /></rule><rule name="infotype"><match url="^(.*/)*infotype-(.+?)-(.+?).HTML?*(.*)$" /><action type="Rewrite" url="{R:1}/e/action/InfoType/index.PHP?ttID={R:2}&page={R:3}" /></rule><rule name="Tags"><match url="^(.*/)*Tags-(.+?)-(.+?).HTML?*(.*)$" /><action type="Rewrite" url="{R:1}/e/Tags/index.PHP?tagname={R:2}&page={R:3}" /></rule><rule name="comment"><match url="^(.*/)*comment-(.+?)-(.+?)-(.+?)-(.+?)-(.+?)-(.+?).HTML?*(.*)$"/><action type="Rewrite" url="{R:1}/e/pl/index.PHP?doaction={R:2}&={R:3}&={R:4}&page={R:5}&myorder={R:6}&tempID={R:7}" /></rule></rules></rewrite></system.webServer> </configuration>
Nginx下伪静态:
rewrite ^([^.]*)/Listinfo-(.+?)-(.+?).HTML$ /e/action/ListInfo/index.PHP?classID=&page= last;rewrite ^([^.]*)/showinfo-(.+?)-(.+?)-(.+?).HTML$ /e/action/ShowInfo.PHP?classID=&ID=&page= last;rewrite ^([^.]*)/infotype-(.+?)-(.+?).HTML$ /e/action/InfoType/index.PHP?ttID=&page= last;rewrite ^([^.]*)/Tags-(.+?)-(.+?).HTML$ /e/Tags/index.PHP?tagname=&page= last;rewrite ^([^.]*)/comment-(.+?)-(.+?)-(.+?)-(.+?)-(.+?)-(.+?).HTML$ /e/pl/index.PHP?doaction=&classID=&ID=&page=&myorder=&tempID= last;if (!-e $request_filename) {return 404;}总结
以上是内存溢出为你收集整理的帝国cms7.2版本默认伪静态规则全部内容,希望文章能够帮你解决帝国cms7.2版本默认伪静态规则所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)