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 10 replies, has 3 voices.

Last updated by veronicaR-2 1 month, 1 week ago.

Assigned support staff: Alejandro.

Author Posts
August 29, 2019 at 11:55 pm #4483883

veronicaR-2

My website runs on a child theme of the theme BLDR Pro. I believe the writing on the homepage as well as the homepage button might be strings but I don't know where to find them to edit them.

Site: liver.ca

August 30, 2019 at 1:30 am #4483973

veronicaR-2

Here's an update - I was able to:

Go to String Translation > Click Translate texts in admin screens > Find theme_mods_bldr_pro-child > Check bldr_first_heading, bldr_second_heading, etc.

When I click on the Apply button, nothing seems to happen. I go back to String Translations and cannot find the new strings I just applied.

August 30, 2019 at 1:40 am #4484027

Mihai Apetrei
Supporter

Languages: English (English )

Timezone: Europe/Bucharest (GMT+03:00)

Hi and thank you for contacting WPML Support!

I will be happy to help you with this.

I am happy to see that you were able to find the strings inside WPML > String Translation > Translate texts in admin screens.

From what I can see, the max input vars value is just 1000 so that might be the reason why you can't check the box next to the fields that you want to add to WPML > String Translation and they are not saved even if you selected the checkbox and hit "Save".

You first need to do this:

We need to increase the MaxInputVars to 50000.

For this, please try to set this variables in your php.ini:

max_input_vars = 50000;
suhosin.post.max_vars = 50000;
suhosin.request.max_vars = 50000;

You may need to contact your hosting provider to set them.

Please make sure you have updated the values successfully, You can verify them from WPML >> Support page.

Now please try to follow the same procedure again and after you save the strings that you checked the box for, you should be able to find them inside WPML > String Translation.

Please let me know how that goes and if that solved the issue.

Kind regards,
Mihai Apetrei

September 4, 2019 at 12:13 am #4507553

veronicaR-2

Hi, setting MaxInputVars to 50000 did not work. Please let me know what else I can do.

September 6, 2019 at 11:51 am #4525091

Alejandro
Supporter

Languages: English (English ) Spanish (Español ) Italian (Italiano )

Timezone: Europe/Rome (GMT+02:00)

Hello, my name is Alejandro,

Since Mihai is currently not available, I will replace him here in the forum.

I hope this is OK with you.

First of all, try to follow this: https://wpml.org/documentation/getting-started-guide/translating-theme-options/#resolving-issues-with-maxinputvars-value

the problem could be that you actually need more than 50.000 in the maxinputvar variable of your installation.

Alternatively you can try the following:

- Position yourself in the page where you found the admin text (WPML > Translation settings > Translate Admin area strings).

- Right click somewhere on the page and click on "View Page source" (this has to be done ONLY when you don't know where the option is, which doesn't seem to be your case so you can skip this step too.)

- When you find the string, return to the Translate Admin area strings page and search for it (if you found the option you were looking for, you can skip this option too).

- Then imagine you have something like what you see in the screenshot below.

The next step would be to write the code you need to use which structure you can find in here: https://wpml.org/documentation/support/language-configuration-files/#structure-and-syntax

in the example case (Screenshot attached) the code would be:

<wpml-config>
    <admin-texts>
        <key name="theme_mods_Avada-Child-Theme">
            <key name="sidebars_widgets">
                <key name="time"></key>
            </key>
        </key>
    </admin-texts>
</wpml-config>

As you can see, we are nesting the code when they are part of accordion items (the one you click and reveal more items inside)

So in this case, first you have "theme_mods_Avada-Child-Theme" as a name attribute for the <key> tag.

then, you can see we are only closing the key tag ( </key> ) at the end, because inside of that key tag we have another element "sidebars_widgets" which also has another item inside: "time" which closes itself because it's the last one and it's not really an accordion item.

Try it out and let me know how it goes!

September 7, 2019 at 6:20 pm #4529739

veronicaR-2

Thank you, I followed the first document and it looks like I need over 60,000 for MaxInputVars. Do you know why I would need it so high? Does it have to do with having so many strings?

September 7, 2019 at 6:44 pm #4529745

veronicaR-2

If I were to try the second option here, I just want to make sure I'm 100% clear on what to do. Say I wanted to translate some of the strings in the attached screenshot. I would insert this code into my wpml-config.xml file?

<wpml-config>
<admin-texts>
<key name="theme_mods_bldr_pro-child">
<key name="bldr_first_heading">
<key name="bldr_second_heading">
<key name="bldr_logo">
<key name="bldr_hero_button_text"></key>
</key>
</key>
</admin-texts>
</wpml-config>

(Where bldr_first_heading, etc. would be nested inside theme_mods_bldr_pro-child)

And place the entire code somewhere in the wpml-config.xml file? And then that would make the string show up in the String Translation area as fields I could edit?

Thanks in advance.

September 9, 2019 at 11:14 am #4536493

Alejandro
Supporter

Languages: English (English ) Spanish (Español ) Italian (Italiano )

Timezone: Europe/Rome (GMT+02:00)

You need so many because the system takes all the options from the XX_options table which basically stores the options of every plugin you have installed on your site (where XX is the prefix of your site).

Since some of the plugins don't delete their options from that database table, it will become huge.

We are actually working to improve that page but it will take time because there's no way to actually go around the content of that table in the database and filter out its content.

about the code. you missed a few closing tags:

<wpml-config>
  <admin-texts>
    <key name="theme_mods_bldr_pro-child">
      <key name="bldr_first_heading">
        <key name="bldr_second_heading">
          <key name="bldr_logo">
            <key name="bldr_hero_button_text"></key>
          </key>
        </key>
      </key>
     </key>
</admin-texts>
</wpml-config>

I suggest that you add that code in WPML > Settings > Custom XML Configuration (it's a tab at the beginning of the settings page) because that page will actually run a verification test and if the structure is not correct it will tell you where is the issue and you'll be able to fix it.

Regards.

September 10, 2019 at 3:50 am #4541563

veronicaR-2

Hello,

I placed that code in WPML > Settings > Custom XML Configuration like you suggested, went to String Translation, searched for the string and I'm not seeing it. Did I miss a step?

September 10, 2019 at 10:26 am #4544137

Alejandro
Supporter

Languages: English (English ) Spanish (Español ) Italian (Italiano )

Timezone: Europe/Rome (GMT+02:00)

To continue, I'll need temporary access to your site, so i can check not just the code but the nesting in the Admin texts page.

I have just activated the appropriate boxes for the credential information i need from you. they are private so only you and i will be able to see them.

I suggest you create a temporary user, set it as an administrator and then add those credentials in the fields mentioned above.

September 11, 2019 at 1:44 am #4549371

veronicaR-2

My issue is resolved now. Thank you! I had the individual strings nested when they shouldn't have been.