VirtueMart Forum

VirtueMart 2 + 3 + 4 => Security (https) / Performance / SEO, SEF, URLs => Topic started by: toto2 on November 11, 2014, 22:00:54 PM

Title: How to remove category name in product url
Post by: toto2 on November 11, 2014, 22:00:54 PM
Hi,

How to remove the category name from the URL when a product is showed ?

For example
/category/subcategory/product.html
will be
/product.html

The reason is to not have a duplicate content when the same product is in two or more different categories

I need your help before put the website online

My configuration :
Joomla 2.5.27
Virtuemart 2.6.12
Sh404sef 4.4.01725

Thanks
Title: Re: How to remove category name in product url
Post by: jjk on November 12, 2014, 21:13:03 PM
I didn't have a look at sh404sef since Joomla 1.6, because I consider it useless for url-management. Last known behaviour I'm aware of when used with VirtueMart was that it achieves compatibility with VM by disabling itself for VM urls. Also it makes large shops slow, because it generates really huge cache files.

Anyway - without sh404sef you can simply ignore your 'duplicate content' problem. A citation from Google:

Examples of non-malicious duplicate content could include:

    Discussion forums that can generate both regular and stripped-down pages targeted at mobile devices
    Store items shown or linked via multiple distinct URLs
    Printer-only versions of web pages

Also, VirtueMart is using a canonical url (points to the first category) when you have a product in multiple categories. So there is no 'duplicate content' problem.

Further reading:
https://support.google.com/webmasters/answer/66359?hl=en
https://support.google.com/webmasters/answer/139066
Title: Re: How to remove category name in product url
Post by: toto2 on November 12, 2014, 23:20:51 PM
Thank you JJK for your help

toto