RewriteRule ^shop/[^/]+/[^/]+/([^/]+)/?$ /shop/$1 [R=301,L]
We have a site where sometimes Google has indexed a page where it is linked like this:
/shop/mens/jeans/jean-product/
But we need it to already redirect to:
/shop/mens/jean-product/
The site is written in this way, but Google has oddly indexed longer versions with the "jeans" in the sub category.
The Rewrite above was given to me, but it doesn't do anything at all.
Can someone please help? Looking at it, surely it should have the various $1...$2 within it, but my knowledge is extremely rusty.