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 5 replies, has 2 voices.

Last updated by herveZ-2 11 months, 3 weeks ago.

Assigned support staff: Bobby.

Author Posts
October 18, 2018 at 9:35 am #2827463

herveZ-2

I am trying to: Translate a string which contains HTML coming from WP Google Maps plugin

I expected to see: Content translated in French

Instead, I got: The original content in english

The content coming from this plugin is well translated when it doesn't contain HTML.

Here is a sample of the content I've translated :
<p>\n J'accepte le traitement de mes données par <span name="wpgmza_gdpr_company_name"></span> .\n</p>

October 19, 2018 at 1:08 am #2829890

Bobby
Supporter

Languages: English (English )

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

Hello,

are you translating the string within WPML String Translation ?

do you include the html in the translation ?

if you are aware of where the string is within the plugin you can try wrapping it with a gettext call and then try to translate it again

https://wpml.org/faq/language-setup/

let me know your results

October 19, 2018 at 7:07 am #2830755

herveZ-2

Hello Bobby,

Thank you for your answer.
I'm doing the translation with WPML String Translation. The HTML is included in the string to translate and in the translation.

I've located the string in the plugin and it's wrapped in a gettext call like this :

__('<p>I agree for ...</p>'), 'wp-google-maps')

I guess I couldn't find it in WPML String Translation if t wasn't wrapped in a gettext call.

October 19, 2018 at 5:27 pm #2832765

Bobby
Supporter

Languages: English (English )

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

Hello,

if possible i would like to take a closer look

**Before we proceed I recommend to please take FULL BACKUP of your database and your website.**
I often use the Duplicator plugin for this purpose See: http://wordpress.org/plugins/duplicator/

I would like to request temporary access (wp-admin and FTP) to your site
(preferably to a test site where the problem has been replicated if possible)

You will find the needed fields for this below the comment area when you log in to leave your next reply.
The information you will enter is private which means only you and I can see and have access to it.

October 23, 2018 at 1:15 am #2840101

Bobby
Supporter

Languages: English (English )

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

Hello,

when i take a look in the backend within the String Translation , i can see a few entries that are duplicates

hidden link

what are your results if you translate all of them

also where can i find this string within the front end , so i can test it out as well.

October 24, 2018 at 6:56 am #2845102

herveZ-2

It was that, I searched only in wp-google-maps domain. The correct translation was in the default domain. It works perfectly now, thank you very much