Google has indexed this page http://[site-removed]/showering-accessories on my client’s site which doesn’t actually exist. The correct URL should be http://[site-removed]/products-page/showering-accessories
I don’t want the site to be penalised in Google, So I’ve added this rule in .htaccess in the root of the site:
RedirectMatch 302 ^/showering-accessories /products-page/showering-accessories
(Note: I had been experimenting with 301 redirects previously)
This works as intended in IE and Firefox, but in Chrome I end up at this page, due to what I assume is a wordpress application-level (PHP) redirect:
http://[site-removed]/products-page/products
Why is this? Shouldn’t the .htaccess rules always kick in before it reaches the PHP code?
How can I fix it?
BTW I also have these rules below the RedirectMatch:
# Redirect all pages to subdirectory /new
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d [OR]
RewriteCond %{REQUEST_URI} /
RewriteRule ^(.*)$ /new/$1 [L,QSA]
That redirect works fine for me when I use chrome. Are you sure your Chrome doesn’t have an old redirect cached or something?