我想重定向
http://www.mysite.com/index.php?channels=browse&channel_id=1&sort=rated
到
http://www.mysite.com/category/cars/?r_sortby=highest_rated&r_orderby=desc
有人可以帮我解决这个问题吗?
谢谢!
答案 0 :(得分:1)
这应该对你有用
RewriteEngine on
RewriteCond %{THE_REQUEST} ^(GET|POST)\ /index\.php\?channels=browse&channel_id=1&sort=rated\ HTTP
RewriteRule ^ /category/cars/?r_sortby=highest_rated&r_orderby=desc? [R=301,L]
编辑:
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !^/category/(.*)
RewriteRule ^(.*)$ /watch.php?tag=$1 [L]