Skip Navigation

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

Problem:
The client was unable to see translations for a specific widget in the language switcher, despite having translated the widget and other content. The widget content was only displaying in Greek, regardless of the selected language.
Solution:
We suggested several steps to resolve the issue:
1. Ensure that translations are not saved in 'Draft' mode and apply any pending translation reviews in bulk via WPML > Translations.
2. Assign the widgets to 'All languages' and use WPML > String Translation to translate them. More details can be found here: Translating Widgets Using String Translation
3. Increase the WordPress memory limit to at least 256MB by adding the following code to the wp-config.php file:

define ('WP_MEMORY_LIMIT', '256M');

This code should be placed just before the comment:

// That's all, stop editing! Happy blogging.

4. After increasing the memory limit, save the widget settings again and check if the issue is resolved.

If these steps do not resolve the issue or if the solution becomes outdated, we 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 the problem persists, please open a new support ticket at WPML support forum for further assistance.

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.

Our next available supporter will start replying to tickets in about 6.79 hours from now. Thank you for your understanding.

This topic contains 28 replies, has 3 voices.

Last updated by Nicolas V. 3 months ago.

Assisted by: Bobby.

Author Posts
June 19, 2024 at 10:21 pm #15758895

Andreas W.
Supporter

Languages: English (English ) German (Deutsch )

Timezone: America/Lima (GMT-05:00)

I can confirm a compatibility issue on my test site using "Pixelemu Display Widgets" that occurs when using one widget per language. I tested here only with default widgets from WordPress (Custom HTML).

Yes, I reviewed your website and you are using one widget per language.

On my test, I can not confirm that this works as expected.

Please instead use one Widget per language and translate the widgets with WPML > String Translation, which is the recommended workflow:

Guide:
https://wpml.org/documentation/getting-started-guide/translating-widgets/#translating-widgets-using-string-translation

The fact, that creating one widget per language is already causing issues on my test site, is something that I can forward to our Compatibility Team for further review, but the final fix will need to be implemented by the author of the plugin, as he is using WPML-related code in his plugin that appears not longer to work as expected, means it seems to be outdated code that used to work in the past, but not any longer.

For example, according to their documentation, the plugin uses "icl_language_code" as a constant which is something that is deprecated and no longer recommended:
https://wpml.org/documentation/support/wpml-coding-api/#language-constants

The author should use this hook instead:
https://wpml.org/faq/how-to-get-current-language-with-wpml/

I will further review the issue that I can confirm on my test site and try to find a working solution. If I can not find a solution, I will escalate to our Compatibility Team.

Further, if you run into specific issues with widgets coming from the plugin "PE Eco Energy" then this might be another issue and we should handle this on a separate ticket as this might require a separate escalation of the issue.

I will run further tests today and create an additional ticket if necessary.

June 20, 2024 at 10:05 am #15762700

Agathon

Hello Andreas,

I am really thankfull about your detailed reply. Is really strange how the entire webiste works properly and this part of a page cannot make it work with traslation.

I've done everything following your instructions, but issue with Language switcher in other languages still persists. (see attached images).

Let me know if you have any update about my issue so i can translate this page for my client.

Regards
Agathon

wpml_2.png
wpml_1.png
June 21, 2024 at 12:34 am #15768560

Andreas W.
Supporter

Languages: English (English ) German (Deutsch )

Timezone: America/Lima (GMT-05:00)

I tried fixing the issue inside "Pixelemu Display Widgets" today on a local test site, but sadly I have not had any success yet.

Anyhow, I can confirm that the plugin works as expected if you assign the widgets to all languages and translate them with WPML String Translation. This is why it would not make much sense to escalate the issue internally, as our team will reply that there is a workaround for the issue and anything else will need to be fixed by the author of "Pixelemu Display Widgets".

Could you please assign one of your widgets to all active languages and translate it with WPML String Translation, to confirm if this solves the issue on your site?

June 21, 2024 at 12:10 pm #15774820

Agathon

Hello,
"Could you please assign one of your widgets to all active languages and translate it with WPML String Translation, to confirm if this solves the issue on your site?"

Did you check my attached images in my previous message JUNE 20, 2024 AT 10:05 AM #15762700. I've done all these following your instructions.

June 21, 2024 at 2:21 pm #15776083

Andreas W.
Supporter

Languages: English (English ) German (Deutsch )

Timezone: America/Lima (GMT-05:00)

I see your examples are used on this page: Δημοφιλείς Προορισμοί

This page was not yet translated. I translated it now.

Now, your widgets use a page condition that involves the Greek page and this is why the widgets do not show up on the translated pages.

This means "Popular Destinations" also must be set on the widget's page conditions to display the widget in English.

hidden link

test EN.jpg
June 21, 2024 at 2:29 pm #15776141

Agathon

I see now it displays english language as well hidden link
Let me fix them all widgets for each page in the corresponding language and let you know.

June 21, 2024 at 2:52 pm #15776309

Andreas W.
Supporter

Languages: English (English ) German (Deutsch )

Timezone: America/Lima (GMT-05:00)

Yes, very good - let me know if further assistance will be needed.

June 21, 2024 at 3:23 pm #15776490

Agathon

Thats so weird. Your example was worked properly.
I've done now pages for all languages and widgets all languages to display in these pages

hidden link

hidden link

hidden link

it display all languages except Greek

hidden link

Create a new one greek page about populas destinations and assgin widgets again one by one?

Regards
Agathon

June 21, 2024 at 4:57 pm #15777216

Andreas W.
Supporter

Languages: English (English ) German (Deutsch )

Timezone: America/Lima (GMT-05:00)

It looks like you deleted pages, specifically the original Greek version. Please recover it from the trash bin.

deleted pages.jpg
June 21, 2024 at 5:10 pm #15777331

Agathon

it was dublicated page, thats why i've deleted it not confusing me.
Anyway page was recovered and now seems to be ok.
Can i ask how i can hide language switcher from footem bottom position and keep only drop down language switcher at the top of the page?

hidden link

June 21, 2024 at 5:14 pm #15777349

Andreas W.
Supporter

Languages: English (English ) German (Deutsch )

Timezone: America/Lima (GMT-05:00)

I am glad to hear that it works now.

My apologies, I enabled the switcher for testing. You can disable it at WPML > Language > Footer Language Switcher.

June 21, 2024 at 5:19 pm #15777413

Agathon

I am really thankful for your time and your support.
Issue was little complicated but you could handle it in a professional way.

June 22, 2024 at 10:21 am #15784232
Agathon

Hello Andreas again,

Sorry for open again this thread. Landing page is workiing properly in all languages
hidden link
But i cannot translate one widget.
I've added it two times to check it and translate in all languages hidden link
But when i change language switcher hidden link every content of this specific wigdet hidden link is loading only with greek language content even if i choose english german or romanian it display greek language content.
I've updated all plugins and clear with W3 Total Cache and also created again from start to check it but with no success. I've scan strings to find them and then translated them via String translation without success.
Am i missing something and i cannot understand what is that?

Regards
Agathon

June 25, 2024 at 4:10 pm #15822931

Nicolas V.
Supporter

Languages: English (English ) French (Français )

Timezone: America/Lima (GMT-05:00)

Hi Agathon,

Andreas won't be available for a couple of days.

As the original issue is resolved and since we limit one issue per ticket, I have opened a new ticket for your additional question regarding widgets, that way I can assist you on that new ticket without waiting for Andreas. Let's continue our conversation on that new ticket:

Keeping one issue by forum threat helps to keep the forum clean and organized, it will also help other users with similar problems to find solutions when searching the forum. Thanks for your understanding.

Agathon confirmed that the issue was resolved on 2024-06-25 16:10:28.
This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.