嗨我有另一个问题,我想改写:
http://example.com/articles/page/id至http://example.com/?rt=articles&pageis=id
我的代码:
RewriteEngine on
Options -Indexes
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^articles/page/(.+)$ index.php?rt=articles&pageis=$1 [NC,L,QSA]
RewriteRule ^articles/(.+)$ index.php?rt=articles&title=$1 [NC,L,QSA]
RewriteRule ^page/(.+)$ index.php?page=$1 [NC,L,QSA]
RewriteRule ^(.*)$ index.php?rt=$1 [L,QSA]
First RewriteRule无效,其他则完美无缺。有人能帮助我吗? 这可以用这种方式重写吗?