2016-04-22 78 views

回答

0

使用重定向指令不能操縱查詢字符串,你需要使用國防部重寫,

嘗試:

RewriteEngine on 

#1)Redirect "?act=view&id=1" to "http://google.com/"# 
RewriteCond %{THE_REQUEST} \?act=view&id=1 [NC] 
RewriteRule^http://google.com/? [NC,L,R] 
#2)Redirect "?act=view&id=2" to "http://facebook.com/"# 
RewriteCond %{THE_REQUEST} \?act=view&id=2 [NC] 
RewriteRule^http://facebook.com/? [NC,L,R]