Question

we have category and product URLs already indexed by google so we need to add/modify Magento URL Rewrites to match those URLs. We are migrating one of the ecommerce store from yahoo to magento, but we can't change the url structure as they are already indexed by google.

So basically, what I want is..

Magento URL: http://www.website.com/cat1/cat2.html Need URL: http://www.website.com/cat2.html

Magento URL: http://www.website.com/cat1/product.html Need URL: http://www.website.com/product.html

Magento URL: http://www.website.com/cat1/cat2/product.html Need URL: http://www.website.com/product.html

At one extent I managed to solve this with product pages, by enabling Canonical URLs for categories and products from backend. But that doesn't help for all the cases, like for multiple categories in the URL.

Any help will be much appreciated!

UPDATE: I have disabled "Use Categories Path for Product URLs" and URLs with products are working as it should be. But the category link is still not solved. If there are multiple categories in the url, then issue still comes.

So, the original Magento URL www.website.com/cat1/cat2.html should be www.website.com/cat2.html only without cat1 in url.

Was it helpful?

Solution 3

Got it solved by using solution from below URL: http://www.magentocommerce.com/boards/viewthread/32328/

Hope this helps someone!

OTHER TIPS

You can solve this via admin setting in system->configuration->catalog->search engine optimization.

'Use Categories Path for Product URLs' set to no, and re-index url_rewrites.

This will remove the category from urls.

It is not possible to get a child category as single name in the url by default in Magento (as your first example). You will need to add your own custom rewrites thru the Catalog>Manage URL rewrites menu. This will create redirects to the real url paths used by Magento (else you would get duplicate content). This way the users entering thru a search engine do get redirected to the correct url and will the search engine learn the new url and you can phase out the redirects.

Licensed under: CC-BY-SA with attribution
Not affiliated with magento.stackexchange
scroll top