WPML

Overview of the Issue

When you use Joinchat and set a page’s own Joinchat settings in its Joinchat box, the translations of the page do not get these settings.

For example, if you hide the chat on an English page, the chat still shows on the Spanish translation of the page. If you give a page its own phone number or Call to Action, the translation uses the site’s phone number and texts instead.

Workaround

Tell WPML how to translate the Joinchat settings:

  • Go to WPMLSettings and open the Custom XML Configuration tab.
  • Add this code and save:
    <wpml-config>
      <custom-fields>
        <custom-field action="translate">_joinchat</custom-field>
      </custom-fields>
      <custom-fields-texts>
        <key name="_joinchat">
          <key name="message_text" />
          <key name="message_send" />
        </key>
      </custom-fields-texts>
      <gutenberg-blocks>
        <gutenberg-block type="joinchat/button" translate="1">
          <key name="message" />
        </gutenberg-block>
      </gutenberg-blocks>
    </wpml-config>
  • Update the translation of each page that has its own Joinchat settings.

This file covers both Joinchat issues. In the translation editor, you also see the page’s phone number and the “view” setting. Keep them, or change them for the language.

All known issues

Need Help with This Issue?

Ask a support question and we’ll look into it with you.