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

Last updated by Bruno 2 years, 4 months ago.

Assigned support staff: Bruno.

Author Posts
May 16, 2017 at 12:15 pm #1277138

gentianG

Dear Support,

I am using Scalia theme, for my website.
I have built two different pages for specific requirements i had, both pages are calculator.
First idea that came up in my mind was to translate strings used on those pages, so i did a scan and strings did not appear.

Second idea was duplicating page and translating it hard coded. Than assign translation, bus seems that WPML catches the fact that is not same template used.

What should i do i this case.
Another issue i am having is Newsletter wordpress plugin. Strings are not found.
They keep using Albanian Language.

Kind Regards,

May 16, 2017 at 7:03 pm #1277604

Bruno
Supporter

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

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

Hello,

Thank you for contacting us.

How are you creating these custom pages? Are template pages? If so, are you using the gettext function to make the strings translatable? You can see the complete WordPress step by step: https://codex.wordpress.org/L10n

For example, if you have content like this:

<div>Hello World</div>

You should change it like this:

<div><?php _e( Hello World ); ?></div>

That way the strings will be available for you to translate them into String Translation.

If this is not what you are asking, can you please elaborate a little more so I can better understand? Sometimes screenshots illustrating what you mean may go a long way to clarify what words fail to transmit so if you like make use of "upload an image" below the comment area.

Thank you.

May 22, 2017 at 9:31 am #1281355

gentianG

Dear Support,

I have followed your instructions and still strings are not being translated. After theme scan, all strings were loaded on String Translation, i have translated them, but in front end no changes are made.

What would you suggest?

May 22, 2017 at 6:21 pm #1282052

Bruno
Supporter

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

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

Hello,

On the WPML > Theme and plugins localization, on the "Select how to translate strings in the theme and plugins" option, make sure that one of the two options are selected:

[ ] Translate the theme and plugins using WPML's String Translation only (don't load .mo files)
[ ] Translate the theme and plugins using WPML's String Translation and load .mo files as backup

If the problem persists, please, what is the version of WPML and WP are you using? I would like to know more about your installation. Can you please provide your WPML Debug information in the debug field below? http://wpml.org/faq/provide-debug-information-faster-support/

Thank you.

The topic ‘[Closed] Custom code not being translated’ is closed to new replies.