Skip Navigation

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

Problem:
The client was unable to translate the WooCommerce Extras section that can be added to single product listings.
Solution:
We recommended adding the following code to the Custom XML Configuration in WPML-> Settings-> Custom XML tab:

<wpml-config>
  <admin-texts>
    <key name="astra-settings">
      <key name="single-product-extras-text"></key>
      </key><key name="single-product-extras-list">
        </key><key name="items">
          </key><key name="*">
            <key name="label"></key>
          </key>
        
      
    
  </admin-texts>
</wpml-config>

After adding the code, we instructed the client to:
1. Go to the String Translation page.
2. Search for "single-product".
3. Delete the four strings related to the section.
4. Search again for "single-product".
5. Translate the strings.
6. Clear the site's cache.
7. Check if the strings are translated correctly.
8. Add a new test product and translate it to check the issue.
We also provided a guide for further information on registering admin strings: https://wpml.org/documentation/support/language-configuration-files/translate-strings-in-wp-options-table/

Please note that the solution might be irrelevant due to being outdated or not applicable to your case. If the issue persists, 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 necessary, do not hesitate to open a new support ticket for further assistance: 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.

Tagged: 

This topic contains 25 replies, has 3 voices.

Last updated by Osama Mersal 1 year, 2 months ago.

Assisted by: Osama Mersal.

Author Posts
February 22, 2024 at 3:14 pm #15334340

klausW-6

Hello,
I cannot figure out how to translate the section Woo Commerce Extras that can be added to single product listings. Everything else here is translated.

Klaus

Screenshot 2024-02-22 at 16.12.49.png
February 22, 2024 at 6:41 pm #15335340

Lucas Vidal de Andrade
WPML Supporter since 11/2023

Languages: English (English ) Spanish (Español ) German (Deutsch ) Portuguese (Brazil) (Português )

Timezone: America/Sao_Paulo (GMT-03:00)

Thank you for contacting WPML support. While you are waiting for one of my colleagues to take this ticket and work on it, let me provide you with first debugging steps or if I can perhaps help with the issue quickly.

Please provide us your de bug information. This way we can understand better what's going on and help you solve your issue quicker.

https://wpml.org/faq/provide-debug-information-faster-support/

Furthermore, please check WPML > String Translation, to see if you find the texts of this specific widget.

If none of that helps, one of my colleagues will soon take over this ticket and further support you 🙂

February 24, 2024 at 3:40 pm #15340649

klausW-6

Hello,
thank you for your reply. I tried but this set (as described above) does not show up in he search of the string translation.
If you have any advice how I can find/translate it, please?

Best,
Klaus

This is the debug information:
https://pastebin.com/440eLb3P

February 25, 2024 at 11:32 am #15341315

Osama Mersal
WPML Supporter since 02/2020

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+03:00)

Hi Klaus,

I'm Osama from WPML forums support. I'll be glad to help you today.

1) Please try the following steps:

1- Go to WPML-> Theme and plugins localization, select your theme/plugin, and scan
2- Go to WPML-> String Translation
3- Scroll down and click on the "Translate texts in admin screens »" link
4- Search for the needed strings
5- Select the strings
6- Click on the "Add to String Translation" button
7- Then click on the "« Return to String Translation" link
8- Translate the strings, clear the cache, and check the front end

Kindly check our guide to know more about translating texts in the admin texts screen. (https://wpml.org/documentation/getting-started-guide/string-translation/finding-strings-that-dont-appear-on-the-string-translation-page/)

2) Please add the debug information in the debug information field.

Best regards,
Osama

February 26, 2024 at 6:59 am #15342297

klausW-6

Dear Osama,

thnak you for your very useful reply - I managed to sort out what was needed! 🙂
However, there is on bit left from the plug-in Germaized. It shows all prizesof sigle products with the "from" prefix in English (the translated language). I followed your instructions anf found the string but it it locked. See the screenshot. How can I deal with that?
Best, Klaus

Screenshot 2024-02-26 at 07.53.42.png
February 26, 2024 at 7:27 am #15342402

Osama Mersal
WPML Supporter since 02/2020

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+03:00)

Hi Klaus,

Please go to WPML-> String Translation and search for the option name. For example, search for this option (woocommerce_gzd) to find the string in your screenshot.

Best regards,
Osama

February 28, 2024 at 6:53 pm #15355535

klausW-6

Hi Osama,
thank you for your last reply. that issue is resolved.

Coming back to the very first issue raised in this thread - the woocommerce Extras are behaving erratically.
There was a brief moment when it actauly worked fine!
Now its back to this situation: They show the German version for both languages even though in the string translations they show as corectly translated. I tried a lot here - even deleted the translated strings and created new ones.
What also just happened is that I changed the terms in the customizer to English vocabulary but as I refreshed it switched it all back to the German words - even through it should have considered my manual input here as 'German' or?
Am at my wits end now. Can you help?
Many thanks,
Klaus

Screenshot 2024-02-28 at 19.44.16.png
Screenshot 2024-02-28 at 19.38.57.png
Screenshot 2024-02-28 at 19.38.26.png
February 29, 2024 at 7:19 am #15356399

Osama Mersal
WPML Supporter since 02/2020

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+03:00)

Hi Klaus,

I would need to look closely at your site, so I would need to request temporary access (WP-Admin and FTP)
Preferably to a test site where the problem has been replicated.

Your answer will be private, meaning only you and I can access it.

❌ Please backup your database and website ❌

✙ I would need your permission to de-activate and re-activate the Plugins and the Theme and change configurations on the site. This is also a reason the backup is critical.

✙ I also need your permission to take a local copy of your site to debug the issue without affecting your live site.

Best regards,
Osama

March 1, 2024 at 4:34 pm #15364041

Osama Mersal
WPML Supporter since 02/2020

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+03:00)

Hi Klaus,

Thanks for the access details. Please translate these strings and check if they work correctly. (hidden link)

Best regards,
Osama

March 4, 2024 at 8:50 am #15368096

klausW-6

Hello Osama,

thank you for your reply. It did work fine for a while but now it is back to the problem as it was. I think it happened once I listed a new product (which I mostly do through duplicating existing ones). What happened now, is exactly what I experienced before: the German vocabulary got overwritten and is now English.

The admin password was changed, so if you need access again, please send another private link.

Best wishes,
Klaus

Screenshot 2024-03-04 at 09.44.52.png
March 4, 2024 at 10:32 am #15368790

Osama Mersal
WPML Supporter since 02/2020

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+03:00)

Hi Klaus,

Please log in to this sandbox site and install the Astra theme. (hidden link)

After that, please create a test product with WooCommerce extras and translate it to replicate the issue.

If the issue is replicable, please let me know to consult our compatibility team regarding this issue.

Best regards,
Osama

March 4, 2024 at 11:34 am #15369089

klausW-6

Hi Osama.
the Extras in question are a feature of Woo payments - they don't even show without setting up a woo payments account on that Sandbox. Is that a safe option to do?
See the screenshots. The Option 'Enable Shipping Text' works fine here.

Klaus

Screenshot 2024-03-04 at 12.30.10.png
Screenshot 2024-03-04 at 12.30.57.png
March 4, 2024 at 12:00 pm #15369232

Osama Mersal
WPML Supporter since 02/2020

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+03:00)

Hi Klaus,

I added a test payment account. Please check if you can replicate the issue.

Best regards,
Osama

March 4, 2024 at 1:30 pm #15369809

klausW-6

Hi Osama,

The 'extras' are still not showing on the sandbox. I tested on a stagig site, al things Woo are deactivated apart from woocommerce itself and the extras are still there. Here the don't showe- I don't know what do do from here.
Klaus

Screenshot 2024-03-04 at 14.23.55.png
March 4, 2024 at 1:32 pm #15369842

Osama Mersal
WPML Supporter since 02/2020

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+03:00)

Hi Klaus,

Please add the new password for the staging site in the next private reply.

Best regards,