Skip Navigation

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

Problem:
The client has a Divi site and is translating it from French to English. They are using the Elegant Themes Bloom plugin for newsletter forms, which requires a custom class to be used by the module to select the proper form. The client is unable to translate the custom module class, which means the translated page still points to the French newsletter form instead of the English one.

Solution:
We recommend registering the "module_class" attribute for translation to allow its value to be directly translated via the Translation Editor. To do this, follow these steps:
1. Refer to the guides on how to register your Page Builder module for translation:
- How to register Page Builder modules and theme options
- Maintaining Divi Builder compatibility with WPML
2. Add the following XML code to the "WPML > Settings > Custom XML Configuration" section:

<wpml-config>  <shortcodes>    <shortcode>      <tag>et_pb_blurb</tag>      <attributes>           <attribute>module_class</attribute>     </attributes>    </shortcode>  </shortcodes><shortcodes><wpml-config></wpml-config></shortcodes></wpml-config>

3. Open the default page and make some changes, then save. Update the translation and you should see the value for the Module_class attribute in the translation editor.

Please note that this solution might be irrelevant if it's outdated or not applicable to your case. If you encounter issues or if the solution does not work for you, 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 you still need assistance, 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.

This topic contains 1 reply, has 2 voices.

Last updated by Prosenjit Barman 1 year, 3 months ago.

Assisted by: Prosenjit Barman.

Author Posts
February 16, 2024 at 7:27 pm #15312956

bernardL-9

I have a Divi site. My site is French and I am in the process of translating it to English. I use a Blurb Module to invite people to subscribe to a newsletter. I use the Elegant Themes Bloom plugin for the newsletter forms (pop-up). Bloom needs that a custom class be used by the module in order to select the proper form. I have a French form and an English form, both having different class selectors.

The Bloom froms work fine. See this link and click the green envelope at the botom left of page body: hidden link

The translated page is here: hidden link
It still points to the French newsletter form and not the English one, because I can't translate the custom module class...

How would I allows module_class to be changed on the translated version of that page without worrying it might be overwriten later on? Is there a way to add some xml code to allow this?

I have attached the shortcode of the Blurb Module to show you the class parameter I am trying to translate.

Thanks,
Bernard

Capture d’écran, le 2024-02-16 à 14.20.45.png
February 19, 2024 at 10:50 am #15317478

Prosenjit Barman
WPML Supporter since 03/2023

Languages: English (English )

Timezone: Asia/Dhaka (GMT+06:00)

Hello Bernard,
Thanks for contacting WPML Support. Sorry for the delay in responding due to the weekend.

I understand what you're looking for. To translate the "module_class" attribute's value, it's necessary to integrate WPML support for this attribute. This integration will allow you to directly translate its value via the Translation Editor. For detailed instructions on how to register your Page Builder module for translation, please refer to the guide provided below.

- https://wpml.org/documentation/translating-your-contents/page-builders/how-to-register-page-builder-modules-and-theme-options/
- https://wpml.org/documentation/support/maintaining-divi-builder-compatibility-wpml/

Given that you've provided the shortcode in the screenshot, I've identified the name of the Attributes. Below, you'll find the XML code required to register the Attribute values for translation.

<wpml-config>
  <shortcodes>
    <shortcode>
      <tag>et_pb_blurb</tag>
       <attributes>
           <attribute>module_class</attribute>
       </attributes>
    </shortcode>
  </shortcodes>
</wpml-config>

Please copy the code and add it to "WPML > Settings > Custom XML Configuration" section.

After adding the code, please open the default page and make some changes there. Save the changes and proceed to update the translation. You should see the value defined for the Module_class attribute in the translation editor.

Please let me know if that helps or if you need further assistance in this matter. I will be happy to help.

Best regards,
Prosenjit

February 19, 2024 at 5:50 pm #15319791

bernardL-9

Thank you very much.
I also realized the title attribute was not translated, so I have included it to the XML provided. It works!