2012-11-06 173 views
0

我嘗試刪除/重定向查詢字符串:的.htaccess刪除查詢字符串和重定向到產品

http://www.myDomain.com/detail/link-526.html?fb_action_ids=10151931158951677&fb_action_types=og.likes&fb_source=aggregation&fb_aggregation_id=288381481237582

要獲得此鏈接:http://www.myDomain.com/detail/link-526.html

任何幫助將是非常讚賞,謝謝。在htaccess文件在你的文檔根目錄

+1

看看這個: - http://stackoverflow.com/questions/7175400/htaccess-redirect-based-on-query-string-and-remove-query-string –

回答

0

嘗試添加此:

RewriteEngine On 
RewriteCond %{QUERY_STRING} (^|&)fb_action_ids= 
RewriteRule ^/?detail/link- %{REQUEST_URI}? [L,R=301] 

注意這一點,如果有Facebook的查詢字符串的東西沒有任何的,但如果你的頁面的內容不斷增加其瀏覽器重定向,重定向可能會循環。

相關問題