我想从/main.php?page=pages & id = gettingpaidfortakingsurveys到/ main/pages/getting-paid-taking-taking-surveys重定向此网址。CakePHP和.htaccess:如何重定向URL与查询字符串
谢谢!
[UDPATE]
我测试了它在我现有的CakePHP的.htaccess并没有奏效。
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteRule ^/main.php?page=(.+)&id=(.+) /main/$1/$2 [NC]
RewriteRule ^$ app/webroot/ [L]
RewriteRule (.*) app/webroot/$1 [L]
</IfModule>
顺便说一下,不要忘记将IfMaodule更改为IfModule。 – 2010-10-25 14:27:47