Skip Navigation

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

Problem:
It was proving difficult to locate a string which continued to be displayed in the default language on the front end on translated pages.

Solution:
Somehow the small string in question ("KM") was wrongly labelled as originally Russian. Locating the text within String Translation the language can be reset to the correct language, and then a translation to Russian provided.

Relevant Documentation:
https://wpml.org/documentation/getting-started-guide/string-translation/how-to-change-the-source-language-of-strings/

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.

Tagged: 

This topic contains 5 replies, has 2 voices.

Last updated by alekseiN 1 year ago.

Assisted by: Nigel.

Author Posts
October 26, 2023 at 8:34 am #14667983

alekseiN

We cannot translate the string "KM" that appears on the checkout page in Russian.
We were looking for a string in string translation. The theme and plugins have already been scanned. We also tried scanning pages for strings. We also tried to find the string in texts in admin screens.

We were looking for documentation, and came across this documentation, but it didn't help us to translate the String.
https://wpml.org/documentation/getting-started-guide/string-translation/finding-strings-that-dont-appear-on-the-string-translation-page/

To see the problem, then you can go to our website and add the product to your cart, and go to the Checkout page. Also select RU in the language switch. In total price you will see that there is a string "KM".
I've added a screenshot showing where that string is located.

hidden link

Screenshot 2023-10-26 113131.png
October 26, 2023 at 10:34 am #14669209

Nigel
Supporter

Timezone: Europe/Madrid (GMT+01:00)

Hi there

I think that KM string refers to VAT, is that right?

What string are you searching for in String Translation? Most plugins are coded with English texts and you would typically search for the original English string.

In case the plugin already provides language files try going to Dashboard > Updates and see if there are new translations available to update.

Otherwise, make sure that you have scanned whatever plugin might be responsible for the VAT string (Maybe "EU/UK VAT for WooCommerce"? Or something else.) Then search for "VAT" in String Translation.

Does that help locate the correct string?

October 26, 2023 at 12:25 pm #14670237

alekseiN

Hi Nigel,

Thank you for your reply.

Yes, KM string refers to VAT. In string translations we searched for VAT, and we have all strings with VAT translated.

We are using the EU/UK VAT for WooCommerce plugin, and we have scanned all strings from the plugin.

October 26, 2023 at 2:17 pm #14671361

Nigel
Supporter

Timezone: Europe/Madrid (GMT+01:00)

Would it be possible to get access to your dev site so that I can run some basic tests myself and see if I can locate the source of the string?

Let me mark your next reply as private so that I can get log-in credentials from you—you may want to create a temporary admin user for me to use that you can later delete. And be sure to have a current backup of your site.

October 27, 2023 at 10:59 am #14677891

Nigel
Supporter

Timezone: Europe/Madrid (GMT+01:00)

Thanks for that.

I've spent quite a while digging into the details as this was proving a very elusive string to locate.

I eventually surfaced a string that looks problematic by doing some queries directly on the database, and I found a string that is labelled as a Russian string containing the "KM" text.

See the screenshot.

I'm not sure where this string is coming from, and it doesn't look like the correct string for the context of the checkout, but it seems to be interfering.

I used the option to "Change the language of selected strings" to switch the language to Estonian ("KM" is Estonian, the other strings are English), and I then translated the string to Russian.

I'm pleased to say that it appears to be working correctly on the front end, if you could please verify.

Note, between you and I we have done a lot of scanning of themes and/or plugins, and those strings have been added to the string translation database table.

When you have finished working on the translations I suggest you go to WPML > Support > Troubleshooting and run the option to cleanup and optimise the string tables. You can always re-scan plugins at any time if you have further translations to do.

Screenshot 2023-10-27 at 11.47.55.png
October 27, 2023 at 12:38 pm #14678979

alekseiN

We have checked and it works correctly.

Thank you for your help!