A website I made originally had the index.php in the url. It now has to be removed which is no problem, but the site is already indexed by google and we need to put 301 redirects from the urls with index.php to the urls without index.php.
The following code is in the .htaccess file:
RewriteEngine on
RewriteRule ^index.php/(.*) <a href="http://www.mysite.com/$1">http://www.mysite.com/$1</a> [R=301,L]
RewriteCond $1 !^(eerstegesprekgratis|images|member_photos|js|system|themes|uploaded|index\.php|admin\.php) [NC]
RewriteRule ^(.*)$ /index.php/$1 [L]Without this rule: RewriteRule ^index.php/(.*) http://www.mysite.com/$1 [R=301,L], the website is working perfect, but visitors can visite http://www.mysite.com/articles/article/ and also http://www.mysite.com/index.php/articles/article/. When I add the above rewriterule the visitor gets redirect the right way, but on the redirected page I get an infinit loop error from firefox.
Can someone help on this one?