Author Topic: Virtuemart product placed in multiple categories generates only one URL  (Read 3014 times)

Zbira

  • Beginner
  • *
  • Posts: 2
Having one Virtuemart product placed in multiple categories. But the URL is generated only from one category. How can i make the url appear differently in each category ?

Example: product
Quote
computer1
is created in Virtuemart product list.

Placed in multiple categories
Quote
computers, home computers, office computers.


Then url of each product I suppose:

Quote
eshop/computers/computer1
eshop/home-computers/computer1
eshop/office-computers/computer1

But this does not happen. The created url is only one for each category:

Quote
eshop/computers/computer1

When browsing categories, the product is listed correctly in each category, but have only one url. For example I am in category

Quote
home computers
the product is listed in this category, ok. But when I click on product detail, it is always redirected to url
Quote
eshop/computers/computer1


The correct should be
Quote
eshop/home-computers/computer1
.

It is bad because it confuses a customer who is redirected to a product in different category.

Have you experiences why product placed in multiple categories does not generate separate url for each category and how to make this without interfering to core code ? Thank you in advance for your tips.

pinochico

  • 3rd party VirtueMart Developer
  • Full Member
  • *
  • Posts: 1197
    • MiniJoomla
  • Skype Name: support-easysoftware
  • VirtueMart Version: 3
I don't know, I don't even want to guess what you're wrong (and you're wrong, because it works correctly on our e-shops), because you didn't provide the original live url so I could click through and do the analysis myself.

I'll wait and see :)
www.minijoomla.org  - new portal for Joomla!, Virtuemart and other extensions
XML Easy Feeder - feeds from products, orders and database table
Virtuemart Email Manager - customs email templates

jenkinhill

  • UK Web Developer & Consultant
  • Global Moderator
  • Super Hero
  • *
  • Posts: 28177
  • Always on vacation
    • Jenkin Hill Internet
When I try this the product URL displayed in the browser address bar shows the correct (new) category for each category, but the canonical URL remains the same as in the first category where the product was published in each case.
Kelvyn

Jenkin Hill Internet,
Lowestoft, Suffolk, UK

Unsolicited PMs/emails will be ignored.

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

Currently using VirtueMart 3.8.9.10473 on Joomla 3.9.28 PHP 7.4.14