我將舊的joomla網站遷移到Joomla 3.0。我將網址更改爲SEF友好網址,我需要將所有舊網址(www.mysite.com/index.php/mypage)重定向到新網址(www.mysite.com/mypage.html) 我試圖添加此網址代碼在我的.htaccess的底部,但它不工作:Joomla 3.0 - 重定向301刪除index.php添加.html
RewriteEngine on
RewriteRule ^/index.php/(.*)$ http://www.nextlog.it/$1 [R=301,L]
RewriteRule ^/index.php/(.*)$ $1.html [R=301,L]
「不起作用」不能清楚地描述問題 –
「不起作用」我的意思是代碼沒有做任何事情。 –
@Olèp:你應該發佈完整的'DOCUMENT_ROOT/.htaccess' – anubhava