2016-08-03 44 views
1

你好我正在嘗試重定向/fr/welterweight.php這是我的網站上的本地文件夾通過apache conf或.htaccess。htaccess有問號

http://www.bluek.com/fr/welterweight.php?c=france這是我自己的另一個網站。

我試圖

RewriteCond %{REQUEST_URI} /fr/welterweight.php 
RewriteCond %{QUERY_STRING} ^welterweight.php$ 
RewriteRule ^/?$ http://www.bluek.com/fr/welterweight.php?c=france 

但它不工作

回答

2

這個規則應該從站點根目錄的.htaccess工作:

RewriteEngine On 

RewriteCond %{QUERY_STRING} ^$ 
RewriteRule ^fr/welterweight\.php$ http://www.bluek.com/$0?c=france [L,R=302] 
+0

您好Anubhava,謝謝你的回答。不幸的是,它不起作用。 給我一個錯誤「這個頁面被重定向了太多次」 – scandalous

+0

好吧試試我現在更新的規則吧 – anubhava

+0

你試過更新規則嗎? – anubhava