News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Question about canonical generation for products assigned to root and son categ.

Started by SteP[IT], April 30, 2015, 09:52:47 AM

Previous topic - Next topic

SteP[IT]

I have noticed that when a product is assigned both to the root and to some son & nested categories, the J3.x/VM3 canonical is always extracted from the latest category in the tree (and not from the root one), causing the url to be very long when you have URL rewriting and many nested categories: is this a wanted behavior, and/or depending from VM or from Joomla?
According to many Google related publications, it seems that having a very short URI could be a vantage: is there a way to get this also in J3/VM3, rendering the URI starting from the first upper category the product is assigned to, instead of rendering it from the deepest one?
Any suggestion/experience will be appreciated.
Regards
J 3.9.2 - VM 3.4.3

MMC EDIZIONI - Italian High-Quality PaperBooks Publisher
Site: https://www.mmcedizioni.it

Studio 42

Hi,
To shorten your urls, you cann add hidden (or not) menu links for the main categories( or sub categories).
if you add a menu with alias cat1 for a category the new url is now : mysite/cat1 and i don't think is an advantage to use short urls for SEO ranking, but Google hate very long URL eg. site/myhomecategoryishere/inmynewsubcategory/youcanbuymynewproduct/nowhereinthisnicepage/newhere/perhapsbetter/toendwithaproduct/myniceproducturlnowhereforinformation-details

SteP[IT]

I've asked that because I've seen that pages having certain keywords in the last portion of their very long url are commonly displayed AFTER pages with shorthen url having same keywords in last string. But I was also meaning not only to short the length, but also to reduce the /dir/dir/dir chain inside the url: also using your suggestion I think the tree will remain unchanged (only shorten) and the choosen main canonical is always the one referring to the last ramification of the cat tree. Am I wrong?
J 3.9.2 - VM 3.4.3

MMC EDIZIONI - Italian High-Quality PaperBooks Publisher
Site: https://www.mmcedizioni.it

Studio 42

Quote from: SteP[IT] on April 30, 2015, 14:37:21 PM
I've asked that because I've seen that pages having certain keywords in the last portion of their very long url are commonly displayed AFTER pages with shorthen url having same keywords in last string. But I was also meaning not only to short the length, but also to reduce the /dir/dir/dir chain inside the url: also using your suggestion I think the tree will remain unchanged (only shorten) and the choosen main canonical is always the one referring to the last ramification of the cat tree. Am I wrong?

Of course you cannot change how the virtuemart core work. But you can shorten the url /dir/dir ... with this trick

If you need to shortent the URLS, then you have to modify the router.php to only get last category and main menu ID then you can have :
mysite/mymenu/mycategory/myproduct as url.
But this can be a blocker for updating virtuemart.