Skip Navigation

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.

Sun Mon Tue Wed Thu Fri Sat
12:00 – 20:00 12:00 – 20:00 12:00 – 20:00 12:00 – 20:00 12:00 – 20:00 - -
- - - - - - -

Supporter timezone: Asia/Karachi (GMT+05:00)

Tagged: 

This topic contains 3 replies, has 0 voices.

Last updated by Noman 33 minutes ago.

Assisted by: Noman.

Author Posts
January 15, 2025 at 10:17 am #16596558

xavierC-5

Background of the issue:
I am trying to translate a string inside of a PHP code snippet for my site hidden link.
I have followed all documentation but cannot find the string to be translated.

The PHP code is inserted via the WPCode Plugin:
<?php
add_action('woocommerce_product_additional_information', 'add_custom_content_to_additional_info'); function add_custom_content_to_additional_info() { _e('

*Image Disclaimer: Due to the digitalization of the image, the display technologies and the lighting, small variations of product color may occur.

', 'insert-headers-and-footers'); }

Symptoms:
The string shows only in English and I cannot find the string to translate it into Vietnamese. I have followed all documentations, scanned themes and plugins but nothing worked so far.

Questions:
What I'm missing that I cannot find the string inside the PHP code snippet using WPML?

January 15, 2025 at 1:39 pm #16597481

Noman
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Hi,

Thank you for contacting WPML Support. Could you please follow the below steps and let me know how it goes:

1. Go to the WPML >> String Translation page and in the Auto register strings for translation section, enable the ‘Look for strings while pages are rendered’ option.
2. Re-visit the page on the front end where the string appears.
3. Re-visit the WPML >> String Translation page and search for that string.
4. Translated the string.
5. After translating the string, uncheck the auto-registration option.

Here is a doc for more details: https://wpml.org/documentation/getting-started-guide/string-translation/finding-strings-that-dont-appear-on-the-string-translation-page/

Please let me know the results,
Thank you

Auto register strings for translation.jpg
January 17, 2025 at 8:59 am #16604863
xavierC-5

Hi Noman,

Thanks for the help. It worked!

I know it's out of your scope, but can you guide me or give me some hints on how I can style this text wrapped on php?

I'm a self-taught web designer and I tried everything but cannot. I'm just trying to give some space above the text I just added on the Additional Information Tab. The text appears really closed to the above line and is difficult to read it.

Appreciate any guidance where to look for it.

Best,
Xavier

New threads created by Noman and linked to this one are listed below:

https://wpml.org/forums/topic/how-i-can-style-this-text-wrapped-on-php/

January 19, 2025 at 8:56 am #16610117

Noman
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Sorry for the delay, I was off during the weekend (Friday-Saturday). Glad to hear the hardcoded string translation issue is solved. For hardcoded text style problems, it’s a different issue and will be handled separately as per our support policy. I've created a new ticket for this at: https://wpml.org/forums/topic/how-i-can-style-this-text-wrapped-on-php/

If the hardcoded string translation issue is solved, please mark this ticket as resolved and we will continue working on the above ticket for it.

Thank you for your cooperation