Skip Navigation

This thread is resolved. Here is a description of the problem and solution.

Problem:
The client is experiencing an issue where the product categories filter is missing in secondary languages when using Husky filters on their WooCommerce site. They expected to see all filters similar to the original language page but found that the filters were not displaying correctly.
Solution:
We identified that Husky filters might not fully support WPML's settings, which prevents the products from being linked to the translated categories. A suggested workaround is to duplicate the products to secondary languages without translating them immediately. Here are the steps to do this:
1. Go to WPML > Translation Management;
2. Use the filters to show only products;
3. Select the products you wish to duplicate;
4. Under the list, select "Duplicate content";
5. Confirm.
This should make the product available for the translated categories. The client can later translate the products if desired.

Please note that this solution might be outdated or not applicable to your specific case. We highly recommend checking related known issues at https://wpml.org/known-issues/, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If this does not resolve your issue, please open a new support ticket at WPML support forum.

This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

Tagged: 

This topic contains 10 replies, has 3 voices.

Last updated by Lucas Vidal de Andrade 8 months, 3 weeks ago.

Assisted by: Lucas Vidal de Andrade.

Author Posts
October 16, 2024 at 2:02 pm

amigosS

Background of the issue:
I am trying to use HUSKY filters as advised (https://wpml.org/plugin/husky-products-filter-professional-for-woocommerce/) to display product categories filter when viewing the site in languages other than the original. The issue can be seen on this page: hidden link. I expected to see all filters like on this page: hidden link.

Symptoms:
The product categories filter is missing in secondary languages. However, I know they exist and are working because I can see them on this translated product category page: hidden link. I have the same error with another filter plugin (original version: hidden link translated: hidden link).

Questions:
Why is the product categories filter missing in secondary languages?
How can I ensure the filters display correctly in all languages?

October 16, 2024 at 2:27 pm
October 17, 2024 at 2:02 pm #16300817

Lucas Vidal de Andrade
WPML Supporter since 11/2023

Languages: English (English ) Spanish (Español ) German (Deutsch ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Hey there,

I'm having some difficulties creating a fresh copy. Unfortunately, your credentials are not available to me. Can you please share them again?

I've enabled the private fields.

October 18, 2024 at 8:41 am
October 18, 2024 at 5:53 pm #16305963

Bobby
WPML Supporter since 04/2015

Languages: English (English )

Timezone: America/Los_Angeles (GMT-07:00)

Hi there,

Lucas is away today so I am stepping in to keep the ticket moving forward.

Typically filters and taxonomies will not display in secondary languages if the products do not exist in the secondary languages.

Your products are not translated in the secondary languages which is why Categories are missing.

I am not sure how Brands and Sizes are added but since Categories are directly linked to the translated versions it is expected they are missing.

As a test to showcase this I did the following:

1. Translated bronze 56k beanie fatso b skully (navy/black) reversible to French

2. Now see the shop in FR and you will notice the Category option showing
hidden link

October 19, 2024 at 8:55 am #16306883

amigosS

Hello and thank you,
is here a way to bypass this since categories and products are set to "translatable but use default if translation doesn't exist" and it would be really time consuming to translate all the products we have. A snippet or something ?
Thank you

October 21, 2024 at 12:54 pm #16312406

Lucas Vidal de Andrade
WPML Supporter since 11/2023

Languages: English (English ) Spanish (Español ) German (Deutsch ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Hey there,

The option you set, "translatable but use default if translation doesn't exist", only redirects the customer to the default language category, if he clicks on a category that is not translated, in a secondary language.

The solution you are looking for, unfortunately has to be done on Husky's side, as it by default won't show the filter if the categories are not fetched. I apologize, but this kind of customization is outside the scope of our support.

October 21, 2024 at 1:14 pm #16312440

amigosS

Hello, ok everyone is sending the ball on the other side of the court. No filter plugins offers what you said.

To be honest, I find it a bit weird to be forced to translate optionally translatable products; they should be linked to the translated categories even if not translated themselves since it's "optional".

Let's say I don't set my product to "translatable". Will it work then ? I mean, I have all (or most of) my categories translated, so it should take all the product into account, right ?

October 21, 2024 at 1:44 pm #16312623

Lucas Vidal de Andrade
WPML Supporter since 11/2023

Languages: English (English ) Spanish (Español ) German (Deutsch ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Hey there,

We are not “sending the ball” anywhere. What you're asking is for WPML support to provide customization code for a 3rd party plugin that is not developed or maintained by us. I hope you can understand that.

Let me be more specific: Husky shows filters, when there are products available that match the criteria for the filter (again, this plugin was not developed by us and this decision has nothing to do with WPML or any of our plugins). In your specific case, it will show categories that have products in them. Since not all your products are translated, the filters are not showing, as there are no products that match the criteria.

Now, answering your specific questions:

To be honest, I find it a bit weird to be forced to translate optionally translatable products;
You are not forced to translate any products. The thing is, if you wish that your product is translated, is shown, and works in secondary languages, you have to translate it. “Translatable” means exactly what the word suggests: you can translate them if you wish.

Let's say I don't set my product to "translatable". Will it work then ?
Not really. Setting products as not translatable, will block other translators that do not have admin access to translate them, and will remove them from your Translation Management list. That's what this setting does.

I mean, I have all (or most of) my categories translated, so it should take all the product into account, right ?
No. Categories have languages, and will only work with products on the same language. If you translate a category and don't translate the products that would be inside it, the category will be empty.
___________

The conclusion here is that, to achieve what you desire, you have to translate the category AND the products. WPML cannot make products available in secondary languages if they are not translated. That's precisely what WPML does, allows you to translate content. If the content is not translated, it won't be available.

Please let me know if you have any other questions.

October 21, 2024 at 2:07 pm #16312836

amigosS

Sorry, I wasn't trying to be offensive. Sorry about that.

I get what you're saying, truly but I'm hoping I could find a solution. No filtering plugins offers this and I though, having only translated categories would do the trick.
I read your answer about the "if we'd set our products as not translatable" but I have another thing about this. let's say we could set them like that and that we would be ok with product not translated (we didn't translate any yet). There is no way, with this settings to have have our products linked to the translated categories ? I'm asking this because if I go on the page of a translated category (let's say this one : hidden link ) I can see all the (not translated) products. It means they are "linked" in a way. They appear as "product in the 'accessoires'" category which is a translated name of the original category 'accessories') You know what I mean ?

October 21, 2024 at 3:07 pm #16313172

Lucas Vidal de Andrade
WPML Supporter since 11/2023

Languages: English (English ) Spanish (Español ) German (Deutsch ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

No need to apologize! I wasn't offended at all. I understand that sometimes clients feel that support services throw them around, I just wanted to make sure to clarify this is not the case.

Answering your direct question:
There is no way, with this settings to have have our products linked to the translated categories?
The category page in question, is the default archive page from WooCommerce, which allows the products to be shown. It's showing the products in the default language, as WooCommerce and WPML allow that to happen.

Unfortunately, this is not the case for Husky. As I said, Husky prevents the products to be shown, or haven't taken WPML's setting in account.
______

There's perhaps a workaround that might be helpful. If you do not wish to translate your products right now, you can duplicate them to secondary languages. You can test that with one product, before doing it in Bulk. Please make a full website backup and follow these steps:

1. Go to WPML > Translation Management;
2. Use the filters to show only products;
3. Select the products you wish to duplicate;
4. Under the list, select "Duplicate content"
5. Confirm

This way, you should have the product available for the translated categories. You can later translate the products, if you wish. Let me know if that helps you.

October 22, 2024 at 10:15 am #16316308

amigosS

Thank you for your understanding.

Ok, this workaround is a good idea. I know it would work since someone (you or your other colleague did this with one product before and it displays the concerned categories.

Now, let's say we'd do this, a few questions :
1- is there a way to "automate" this duplication ? Every time we add a product using the dashboard or our desktop app (that uses rest api to add products). Like a snippet or something.
2- If I were to edit a product on the original language, would it edit the translation too (stocks, content, image etc.. all of it actually).

Thank you !

October 22, 2024 at 2:31 pm #16318129

Lucas Vidal de Andrade
WPML Supporter since 11/2023

Languages: English (English ) Spanish (Español ) German (Deutsch ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Hey there:

Is there a way to "automate" this duplication ?
No, there's no way to automate the duplication. The only thing that can be automated is automatic translation, which costs credits.

If I were to edit a product on the original language, would it edit the translation too?
Yes. You can make a test with one of your products. They should stay in sync.

October 23, 2024 at 2:21 pm #16322314

amigosS

Alright thank you!
I talked with the HUSKY guys and offered them a solution by querying original categories products count instead of the translated ones, they'll look into it.
Thanks for your answers. I'll keep your solution in mind is they can't do it.