Skip Navigation

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

Problem:
You are working on a site under development and trying to translate sections of your Elementor pages using WPML. Some parts of your Elementor pages are not translating, and you are unable to get the XML file for translation.
Solution:
We recommend the following steps to resolve the issue:
1. Add the following XML in WPML >> Settings > Custom XML Configuration section:

<wpml-config><elementor-widgets><widget name="bdt-switcher"><fields><field>switch_a_title</field><field>switch_b_title</field><field>element_pack_widget_tooltip_text</field><field>switch_a_content</field><field>switch_b_content</field></fields></widget><widget name="bdt-accordion"><fields><field>element_pack_widget_tooltip_text</field></fields><fields-in-item items_of="tabs"><field>tab_title</field><field>tab_content</field></fields-in-item></widget></elementor-widgets></wpml-config>

2. Make a small change in the default language page title to reload the translation and press the Update button.
3. Remove the change made in step 2 and press the Update button again.
4. Click on the secondary language icon to open up the page in Advanced Translation Editor and add the translation.
If the issue persists, you might need to implement a workaround for a known issue with Elementor tabs not displaying translated templates correctly. Follow the steps outlined in this errata: https://wpml.org/errata/exclusive-addons-elementor-tabs-widget-does-not-display-the-elementor-template-translation/
If these solutions do not resolve your issue or if they seem outdated or irrelevant to your 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 needed, 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.

This topic contains 15 replies, has 2 voices.

Last updated by Noman 3 weeks, 4 days ago.

Assisted by: Noman.

Author Posts
October 20, 2024 at 9:34 am #16308285

Noman
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

I’ve followed the below steps:

1. Created a template A in the default language with the default Elementor elements.
2. Created a template B in the default language with the default Elementor elements.
3. Edited the test page in the default language and choose the newly created templates for Tab 1 and Tab 2.
4. Translated the test page in the secondary language.

But it was still loading the default language templates in secondary language. Then, I implemented the workaround from this errata: https://wpml.org/errata/exclusive-addons-elementor-tabs-widget-does-not-display-the-elementor-template-translation/ by following the below steps:

1. …/wp-content/plugins/exclusive-addons-for-elementor/elements/tabs/tabs.php file.
2. Replaced below code:

<?php echo Plugin::$instance->frontend->get_builder_content_for_display( $tab['exad_tab_content_save_template'] ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>

With:

<?php 
    // WPML Workaround for compsupp-6922
    if (class_exists('Sitepress')) {
        $post_type = get_post_type( $tab['exad_tab_content_save_template'] );
        $tab['exad_tab_content_save_template'] = apply_filters( 'wpml_object_id', $tab['exad_tab_content_save_template'], $post_type, true );
    }                               
     
   echo Plugin::$instance->frontend->get_builder_content_for_display( $tab['exad_tab_content_save_template'] ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
?>

And now it shows the correct translated template in secondary language as you can see in the attached screenshot.

Here is the page link:
hidden link

Please let me know if this resolves the issue or if you need further assistance with this issue.

Thank you for your continued cooperation and patience. We truly appreciate it.

FR Tab 2.png
FR tab 1.png
EN tab 1.png
EN tab 2.png