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

Last updated by Marcos Vinicios Barreto 3 months, 1 week ago.

Assigned support staff: Marcos Vinicios Barreto.

Author Posts
July 3, 2019 at 5:08 pm #4138305

elisaK

I am trying to:translate string

Link to a page where the issue can be seen:
hidden link
I expected to see:

Instead, I got:

July 3, 2019 at 5:16 pm #4138347

elisaK

I have add
__('Ho letto e accetto l\'informativa <a href="">Privacy</a>', 'motopress-hotel-booking');
in functions.php and scan for strings to translate but still not changing on front end.
What i am doing wrong?

July 4, 2019 at 1:07 am #4139385

Marcos Vinicios Barreto
Supporter

Languages: English (English ) Portuguese (Brazil) (Português )

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

Hello,

Thank you for contacting WPML Support. I took a detailed look in your website and noticed for the english version you have "I have read and accept Privacy" for the italian version you have "Ho letto e accetto l’informativa Privacy" which part of the string you need to translate? If it is the "privacy" part the you can enter it in italian in your gettext function __() and then translate it into english using the String Translation. Please, let me know if it makes sense, I am happy to provide you with further details in case the above are not enough. Have a nice day.

July 4, 2019 at 10:47 am #4142503

elisaK

Yes but on English i am using jQuery script to translate text and not WPML. You have noticed that there is no link in EN version. We still need help and i will gladly provide login info.
Maybe i miss textdomain or it is wrong gettext function idk anymore.
Text is entered in default lan IT and i added in functions php
__('Ho letto e accetto l\'informativa', 'restaurant-reservations');

July 4, 2019 at 2:02 pm #4144209

Marcos Vinicios Barreto
Supporter

Languages: English (English ) Portuguese (Brazil) (Português )

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

Hello,

Thank you for the updates. I would like to request temporary access (wp-admin and FTP) to your site to take better look at the issue. 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.

Our Debugging Procedures

I will be checking various settings in the backend to see if the issue can be resolved. Although I won't be making changes that affect the live site, it is still good practice to backup the site before providing us access. In the event that we do need to debug the site further, I will duplicate the site and work in a separate, local development environment to avoid affecting the live site.

Privacy and Security Policy

We have strict policies regarding privacy and access to your information. Please see:
https://wpml.org/purchase/support-policy/privacy-and-security-when-providing-debug-information-for-support/

**IMPORTANT**

- Please make a backup of site files and database before providing us access.
- If you do not see the wp-admin/FTP fields this means your post & website login details will be made PUBLIC. DO NOT post your website details unless you see the required wp-admin/FTP fields. If you do not, please ask me to enable the private box. The private box looks like this: hidden link

Please, let me know if you need any additional details. Have a nice day.

July 5, 2019 at 4:58 pm #4152963

Marcos Vinicios Barreto
Supporter

Languages: English (English ) Portuguese (Brazil) (Português )

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

Hello,

Thank you for the updates. I took a detailed look in your website and could identify your issues, here are the results of my investigations:

1 - Your code in your child theme functions.php file is not hooked into any existing theme hooks. In order words your code is not linked to any place in your theme files, it exists isolated in your functions.php file, while WPML is able to scan it, it will never be displayed anywhere.

2 - This is not the way to translate plugins/themes options with WPML, instead you would need to leverage the String Translation feature to accomplish it, for that, please follow the steps below:

2.1 - At first remove this custom code from your child theme functions.php file and your footer.php file as well.

2.2 - In your WordPress Dashboard > WPML > Strings Translation click the blue 'Translate texts in admin screens' at the bottom of the Strings Translation admin section.

2.3 - Look for the 'consent-statement' under the 'rtb-settings' text domain, check it and click the blue 'Apply' button at the bottom of this admin section (I have performed this step for you).

2.4 - Now back in WordPress Dashboard > WPML > Strings Translation click to find the 'admin_texts_rtb-settings' text dpmain and translate the key '[rtb-settings]consent-statement'.

See:
https://wpml.org/documentation/getting-started-guide/string-translation/
https://wpml.org/documentation/getting-started-guide/translating-theme-options/

As regarding your Contact Form 7, I would kindly ask you to open a new ticket for that, so we can deal specifically with your new issue. Please, let me know if the steps above help to solve your issue, have a nice day.

July 5, 2019 at 5:48 pm #4153213

elisaK

First of all thanks for help.
Problem is still there. I followed your instruction step by step and translated string and click as complete, but when i go to the front end it's stay the same on IT lang.
Here is link hidden link it is text right next to checkbox on booking form.
Thanks

July 5, 2019 at 7:13 pm #4153739

Marcos Vinicios Barreto
Supporter

Languages: English (English ) Portuguese (Brazil) (Português )

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

Hello,

Please, take a look at my private reply above. Thanks!

July 5, 2019 at 8:49 pm #4153937

elisaK

i have tried and work well with translating that part. On our part must be some plugin that making that problem. Thank you very much for helping me.

July 8, 2019 at 7:26 pm #4165469

Marcos Vinicios Barreto
Supporter

Languages: English (English ) Portuguese (Brazil) (Português )

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

Hello,

Please, let me know if you managed to solve it in your part, if not, please, try a plugin troubleshooting disabling all of them and keeping just WPML and your booking form plugin activated, then try the same steps you tried in the sandbox environment and let me know if it works on your side. Thank you for your collaboration, have a nice day.