Home >Backend Development >PHP Tutorial >一个伪静态的写法有关问题

一个伪静态的写法有关问题

WBOY
WBOYOriginal
2016-06-13 12:07:08952browse

一个伪静态的写法问题
请教,要写一个伪静态,把一类帖子地址都统一转到一个地址上去

同类型帖子地址是这样

www.abc.com/xiaozu/tiezi/20140601/1.html  (都是这个类型的帖子)

要把这些地址都改成 :www.abc.com/xiaozu/301.php?go=20140601/1.html  

我这样写伪静态格式是不是有错,试了没反应

RewriteRule ^(.*)/xiaozu/tiezi/(.*)/(.*)$ $1/xiaozu/301\.php\?go=$2/$3
------解决思路----------------------
RewriteRule ^xiaozu/tiezi/(.*)$ xiaozu/301.php?go=$1
------解决思路----------------------


RewriteEngine On
RewriteBase /

RewriteRule ^xiaozu/tiezi/(.*)/(.*)$ xiaozu/301.php?go=$1/$2

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn