Magento Forum

   
Canonical urls
 
BWorldNL
Jr. Member
 
Total Posts:  2
Joined:  2012-01-03
 

Hi,

I was asked about canonical urls in Magento but having some questions.
I am not very familiar with Magento but Zend Framework is something I work with most of the time.

What I want is when you have the structure like:

-- Shoes <---- Category
----- Running <---- Category
-------- Product 1 <---- Product
-------- Product 2 <---- Product
----- Walking <---- Category
-------- Product 1 <---- Product

Then I would like to have my urls like:

http://www.mywebshop.com/shoes/running/product-1/
http://www.mywebshop.com/shoes/running/product-2/

http://www.mywebshop.com/shoes/walking/product-1/

http://www.mywebshop.com/shoes/running/product-1/

I think about overriding the router methods: assemble() and route() but it will be expensive and maybe a performance killer so I guess I need to find out how the Magento caching is working, my question here is:

What is the best practice for implementing this behavior. Am I completely wrong here or is it the correct way?
In short: I need some advice here and a push in the right direction…

Thanks!

 
Magento Community Magento Community
Magento Community
Magento Community
 
tzyganu
Mentor
 
Avatar
Total Posts:  2205
Joined:  2009-11-18
Bucharest, Romania
 

Go to system->configuration->catalog->Search Engine Optimizations and set ‘Use Categories Path for Product URLs’ to ‘yes’.
Clear your cache, rebuild you indexes and try again.

Marius.

 
Magento Community Magento Community
Magento Community
Magento Community
 
BWorldNL
Jr. Member
 
Total Posts:  2
Joined:  2012-01-03
 

Great! I will try that out.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
    Back to top