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 thread is resolved. Here is a description of the problem and solution.

Problem: Some of my strings cannot be translated. I registered them using the language configuration file but it didn't help.

Solution: When you register your strings using the language configuration file, please double check if you use the correct option names or if you didn't do any typos. Also, check if the file is uploaded in the correct place. If you use a child theme, wpml-config.xml file should be added to the child theme's root folder.

Relevant Documentation: https://wpml.org/documentation/support/language-configuration-files/

This topic contains 9 replies, has 2 voices.

Last updated by paulL-22 2 years, 7 months ago.

Assigned support staff: Joanna.

Author Posts
January 14, 2017 at 10:46 pm #1182274

paulL-22

I am trying to: make a multilingual website(English/french)

URL of (my) website where problem appears:rapromih.com/promotion

I expected to see: when I am in french all words in french

Instead, I got: some words in English while I am in french version

Steps to duplicate the issue:

January 16, 2017 at 11:38 am #1182872

Joanna

Hello @paull-22,

Please let me know if the problem still occurs if you deactivate Loco Translate.

If not, please tell me how do you add the registration form? Is it a part of your theme or is it added by one of your plugins, or something else?

Can you find the label strings on WPML->String Translation or are these strings missing there?

Are the registration form strings the only strings that are missing their translations?

Additionally, I noticed that your WP Memory Limit is set to 40MB and the WPML's minimum requirement is to have it on 128MB. You can easily increase the memory allocated to PHP. You'll find more info about it at https://codex.wordpress.org/Editing_wp-config.php#Increasing_memory_allocated_to_PHP.
In brief:
1. Log into your FTP.
2. Edit the wp-config.php file.
3. Add the following code:

define( 'WP_MEMORY_LIMIT', '128M' );
define( 'WP_MAX_MEMORY_LIMIT', '256M' );

4. Save the file.

This will not resolve your issue, but it may save you from a headache in the future when you will have possibly stumbled upon some unexpected issues.

January 16, 2017 at 8:46 pm #1183365

paulL-22

I deactivate loco translate, I found the label strings in the admin text fields. I translate them in the string translation but the french translation doesn't display when I am in french. Still the same problem. The registration form is part of User pro plugin that is compatible with WPML. The texts "Under Microscope" and "Read more": are part of MH magazine theme which is compatible with WPML. Those texts are user input.
Before those settings, I increase the memory limit as per your recommendation.
I sent some images to understand what I am saying.
I am waiting for your help.

January 17, 2017 at 11:01 am #1183745

Joanna

Hello @paull-22,

Thank you for the detailed description and screenshots.
As you noticed, the plugin you use is officially compatible with WPML so everything should work correctly. We need to find the reason why it's not working on your installation.

In this case, if it's okay with you, I’d like to replicate your website locally. This will help me debug the issue and find the solution. For this, I'll need a snapshot of your site which you can create using a plugin called "Duplicator". This will allow me to create a copy of your site and your content.

If you already know how Duplicator works (http://wordpress.org/plugins/duplicator/), please send me the installer file and the zipped package you downloaded.

Here's a great tutorial on how to use it: hidden link.

Please send me both files (you probably want to use DropBox, Google Drive, or similar services, as the snapshot file will be quite big). Your next reply will be private, which means that only you and I will be able to see it and have access to it. You can paste the links to the files there. You can also install the Duplicator plugin, create a snapshot and share the credentials to your website. I will then download the files from the admin panel.

If you choose to share the credentials, I'd also be able to check the issue on your website in case I'm unable to replicate it locally.

Once the problem is resolved I will delete the local site.

January 17, 2017 at 4:57 pm #1184180

Joanna

Hello @paull-22,

Thank you for the credentials. I'll check your website and get back to you.

January 18, 2017 at 12:20 pm #1184869

Joanna

Hello @paull-22,

Regarding the strings from your theme, it turned out that the key name in wpml-config.xml was incorrect ("mh_options" instead of "mh_magazine_options"). I changed that. I also moved the wpml-config.xml file to your child theme's root folder.
Now, you can find both strings on WPML->String Translation. When you translate them and mark the translations as completed, everything should work fine.

A similar situation was with the UserPro plugin. The proper keys were missing from wpml-config.xml file. I added the following code to the wpml-config.xml file in the UserPro's root folder:

<key name="userpro_fields_groups">
    <key name="*"/>
</key>

This code adds all fields from "userpro_fields_groups" to the String Translation table. You can find them under the "admin_texts_userpro_fields_groups" domain. You'll need to add proper translations to the form labels.
I already added the translation for the "Confirm your Password" string. You can check on the frontend that the translation displays correctly.

You can change the code added to the wpml-config.xml file to have only needed strings added to the String Translation Table. You'll need to edit the file manually and change the following line:

<key name="*"/>

to list of all fields you need, e.g.:

<key name="register">
    <key name="default">
        <key name="user_pass_confirm">
            <key name="label" />
        </key>
    </key>
</key>

You can find more information about language configuration files at https://wpml.org/documentation/support/language-configuration-files/

Please let me know if you still have any issues with mentioned strings.

January 18, 2017 at 10:38 pm #1185435

paulL-22

Thank you. I start translating the strings, everything seems good. When I finish with all the strings translation, I will come back for a final reply on this issue.

January 19, 2017 at 1:43 am #1185488

paulL-22

The strings translation work fine but there is a new issue. I didn't have this issue before. I will show you the new issue in the screenshot below. The placeholder for " Mot de passe" and "Confirmez votre mot de passe" didn't show up while they showed up in the English translation.
Could you please take a look at this issue because it came after your intervention.

January 19, 2017 at 12:13 pm #1185930

Joanna

Hello @paull-22,

I left your website just as I found it. The only change was that you had more strings registered in your String Translation table but this shouldn't cause any issues.

The issue you had (with the missing form fields) occurred because you translated too many strings. As I mentioned in my previous reply, you were supposed to translate only form labels. However, it's not hard to get lost in the translation process and translate whatever seems to need translation. Besides labels, you translated form input types as well. That led to the situation where your input fields didn't have the proper arguments that determine the type of the field, its style, etc.

I corrected the translations and everything seems to work as expected again. Please double check your forms. If you find any missing field, check on WPML->String Translation if the type of this fields is not translated (it shouldn't be).

January 19, 2017 at 3:36 pm #1186163

paulL-22

Thank you so much for your help. Everything is now working fine. I learn a lot in this process due your help.

Thanks again.