News:

Support the VirtueMart project and become a member

Main Menu

mod_virtuemart_languages work on product without category tree

Started by Darko F., May 23, 2020, 13:23:53 PM

Previous topic - Next topic

Darko F.

Hi all
I need some help,
Joomla version, 3.9.18.
VirtueMart 3.8.2 10325

I have website with 3 languages but I will try to explain only with two  so will make it easier.

I want to use Language switcher module (mod_virtuemart_languages)  which came with payment membership and allow to switch languages between products.
I have long term (10years) experience with joomla and im quite sure all my multilanguage set up and menu is correctly. But im new to virtuemart.

(Website is not public so if you visit this links here will not work)

So my problem:

On level of categories everything working OK.
https://tuamv.com/sl/trgovina/siri
switch OK correctly to
https://tuamv.com/en/shop/cheeses
(Siri and cheeses are category)

On the product level
https://tuamv.com/en/shop/cheeses/test-produkt-en
language switcher switch to
https://tuamv.com/sl/trgovina/test-produkt-sl
(without category tree structure - /siri/-and fall to the main category)

My exspecting and wanted result  is
https://tuamv.com/en/shop/cheeses/testni-produkt-en
to
https://tuamv.com/sl/trgovina/siri/testni-produkt-sl
(with /siri/ category)

Hence if product have a parent and is the child product
https://tuamv.com/en/shop/cheeses/testni-produkt-en-child
Work as I expected  and redirect to
https://tuamv.com/sl/trgovina/siri/testni-produkt-sl-child

So how should I make that also parent product and product without children switching between languages with a category tree structure.?

Thank you all for answer in advance :)
There in no problem if you fall. Problem is if you don't get up

Darko F.

So I manage to make it work.

I will post here maybe somebody will find useful

In Configuration - SEO Settings
I enable:
Use Product and Category IDs   
and also
Use full category tree for product links, which I already have.

Now I get in URL also: category_name/cat_id/ product
URL is little longer but since this don't have much impact on SEO I can live with that.

Language switching now working as expecting.
There in no problem if you fall. Problem is if you don't get up


Darko F.

Hi,
I try your module because I find if I use Product and Category IDs   in SEO settings
When I go frontpage to product and choose Manufacturer and see all manufacturer product - link don't work,  is like this:
mysite/manufacturer/0 
If I disable use Product and Category IDs   in SEO settings link work

When I install your Shop Language Switcher I get same results as with (mod_virtuemart_languages) as I describe above ewen if I enable Product and Category IDs   in SEO settings.

Every time I switch language I lose one category  in url
There in no problem if you fall. Problem is if you don't get up

Studio 42

I think that the problem is perhaps because you use multiple categories affected to your products ?
But why use ID in the link ? This should only be used if you have conflict in the SEF links

Darko F.

Hi
thank you for your reply.
I use ID in link because other ways when I switch language I lose one category every time.
Isn't Virtuemart supposed to work with multiple categories?
There in no problem if you fall. Problem is if you don't get up

Studio 42


Darko F.

Hi
I aegean double check just to be sure and yes all categories have translations in all three languages.

Also I did all correspondent Joomla menus with each Category layout to virtueMart categories and assign Languages to them

I know and read that I shuld have only one main menu with Category layout  but I dont know how otherways set lot of joomla modules in each category. I need stuff like baners and custom modules and so on.

I have product only in the last category of category three
Shop -> Wines -> White wine
Product is only in White wine category could be this problem?

And also when I switch betwen child product all work OK
Only betwen parent product I lose one category each time I change language
There in no problem if you fall. Problem is if you don't get up

Studio 42


Darko F.

Hi thank you for interes in my website

is true like I mentioned above (Website is not public so if you visit this links here will not work)

But I seen you accreditations via your email .....france@...mail.com

Please go and take a look
There in no problem if you fall. Problem is if you don't get up

Darko F.

After a week of testing I find it works also correctly if I in Joomla (Shop) menu

Disable menu item with Top level Category

When I disable menu item with Top level Category and all other menu item categories are selected with corresponded category Shop - Wines - White wines - product language switcher switch between product with full category tree.

Even now all work correctly I asking my question is :
Is a correct setup for Joomla VirtueMart menu to NOT have menu item with Top level category.?

In every forum I read I should have menu item with Top level category, but how then I will make mod_virtue mart_languages to work correctly.

I will publish in few day this shop I just want correct setup before I do

Thank you
There in no problem if you fall. Problem is if you don't get up

Milbo

Quote from: DarkoF on June 05, 2020, 12:18:14 PM
I know and read that I shuld have only one main menu with Category layout  but I dont know how otherways set lot of joomla modules in each category. I need stuff like baners and custom modules and so on.
Where did you read that? This is wrong. The rule is,

You must have at least one menuitem using the category view (category is imho unimportant)

Quote from: DarkoF on June 05, 2020, 12:18:14 PM
I have product only in the last category of category three
Shop -> Wines -> White wine
Product is only in White wine category could be this problem?

And also when I switch betwen child product all work OK
Only betwen parent product I lose one category each time I change language
That should work that way. You could create a menu item with "wines" or items with the subcategories, or both. If you want it multilanguage you need any menu at least with * and for any language. so for 2 languages 3 times the same menu structure.
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/