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.

This topic contains 18 replies, has 2 voices.

Last updated by vadimP 8 months, 3 weeks ago.

Assigned support staff: Osama Mersal.

Author Posts
February 22, 2021 at 2:21 pm #8145603

vadimP

Hi! I have an issue with translating a Toolset content template. This issue came up after the last Toolset update.
Here are example pages in both languages that use this template:
hidden link
hidden link

The template is translated with WPML but those translated texts don't display in English version.

February 23, 2021 at 2:15 pm #8154823

Osama Mersal
Supporter

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+02:00)

Hi,

Thanks for contacting WPML forums support. I’ll be glad to help you today.

1) Could you please tell me how did you translate the mentioned pages? Did you use Classic Translation Editor, Advanced Translation Editor, WordPress Editor, or Translation Service?

2) Could you please share your Debug information with me?
You can read a detailed explanation about it here.
http://wpml.org/faq/provide-debug-information-faster-support
The debug info will give me a lot of information about how your site is configured and will help me understand the source of the problem.

Thanks for your cooperation

Best regards,
Osama

February 25, 2021 at 10:10 am #8171021

vadimP

Hi!

1) The content template was translated using Classic editor - will attach screenshot. Just want to clarify that this translation worked for a period of time, but then stopped working, most likely after Toolset update.
I've also tried Advanced editor for content template translation earlier but it broke the pages.

(For page translations themselves – parts of the page that are separate from Toolset Content template – we used regular WordPress page editor, and it works just fine.)

2) Debug info added.

Screenshot 2021-02-25 at 12.06.09.png
February 25, 2021 at 10:18 am #8171131

Osama Mersal
Supporter

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+02:00)

Hi,

1) Thanks for the update. According to the Debug.info provided, the WP memory limit needs to be increased. PHP memory is fine, but WordPress uses 40Mb as default. Minimum requirements for WPML are 128Mb. (Kindly check this page https://wpml.org/home/minimum-requirements/)

Please, add this to the top of wp-config.php to increase WP memory.

/** Memory Limit */
define('WP_MEMORY_LIMIT', '256M');
define( 'WP_MAX_MEMORY_LIMIT', '256M' );

2) Also, I would need to take a closer look at your site. So I would need to request temporary access (WP-Admin and FTP)
– preferably to a test site where the problem has been replicated if possible –
in order to be of better help and check if some configurations might need to be changed

Your next answer will be private, which means only you and I have access to it.

❌ Please backup your database and website ❌

✙ I would additionally need your permission to de-activate and re-activate Plugins and the Theme and to change configurations on the site if needed. This is also a reason the backup is critical.

Thanks for your cooperation

Best regards,
Osama

February 26, 2021 at 8:44 pm #8184383

Osama Mersal
Supporter

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+02:00)

Hi,

Thanks for providing the access details. I've checked your site, and I found some custom fields not set to translate, so I set them to be translated.

Could you please try to retranslate this coach and tell me if it worked correctly for you?
(hidden link)

Thanks,
Osama

March 1, 2021 at 2:13 pm #8197869

vadimP

Hi!

It looks exactly the same as before unfortunately.

Just to reiterate, the parts that don't get translated are from the Content template (here: hidden link) called "Coach single template". I will include a screenshot with some of the elements that come from that template.

Texts that are translated inside the actual coach page (not the content template) work just fine.

Do you suggest we purge the current English template translation and re-do it again?

Screenshot 2021-03-01 at 16.09.10.png
March 1, 2021 at 3:35 pm #8198785

Osama Mersal
Supporter

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+02:00)

Hi,

Thanks for the update. I think retranslating the content template might help, but please take your site's full backup first.

Please let me know if it works. If it didn't, I'd continue working on this issue.

Thanks,
Osama

March 1, 2021 at 4:19 pm #8199581

vadimP

Hi!

In this case can you please instruct how to delete the old translation? WPML controls for content template are not the same as for regular pages and I don't see a way to delete translation without deleting the whole content block.

March 1, 2021 at 5:02 pm #8199931

Osama Mersal
Supporter

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+02:00)

Hi,

Unfortunately, it seems that you have to delete the content template itself and then recreate it and translate it. Could you please use a different name for the translated template?

Thanks for your cooperation, and sorry for the inconvenience.

Thanks,
Osama

March 12, 2021 at 4:00 pm #8296003

vadimP

Hi!

I've tried to do as you've suggested on a test site and so far it didn't work.
You can access test site here (same user details as previously provided for the live site): hidden link

I'm wondering if the issue is with the shortcode that's used on each Coach type page, eg.:
[wpv-post-body view_template="single-coach-template"]
Do we need to enter a different value of view_template for translated content? So instead of "single-coach-template" (which is originally in Russian) it's a value that leads to English version of that template instead?

March 12, 2021 at 4:08 pm #8296045

Osama Mersal
Supporter

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+02:00)

Hi,

I think the shortcode should be different for each language. That's why I've asked to change the name of the English content template.

I'll check the test site too. Maybe I'll catch what causes the issue.

Thanks for your cooperation

Regards,
Osama

March 18, 2021 at 10:27 am #8340591

vadimP

Hi!

Have you had any progress with checking this issue on the test site?

So far I've tried adding another content template (not a translation, but a separate new one) with English texts and using its shortcode in EN version of the Coach pages. Translation itself works, but this way another issue appears - main image of the coach and one of the fields in the sidebar aren't displaying anymore. Maybe it has something to do with the fact that new content template isn't assigned to Coach type pages (as far as I know only one template per page type can be assigned but correct me if I'm wrong).

I've also tried using [wpml-string] to wrap the texts that need to be translated to EN but no luck. Texts do appear in Strings and can be translated, however translations don't appear in front-end.

Please let me know - is there something else can we try to make it work? Thank you.

March 18, 2021 at 12:42 pm #8342115

Osama Mersal
Supporter

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+02:00)

Hi,

I'm so sorry for the late reply. I've also tried many solutions with no luck, but with your last update, I was able to fix the image issue with replacing your code with the following code.

<div class="col-md-5 picture-tab" style="background-image: url([wpv-post-featured-image="" size="" output='url']);">&nbsp;</div>

The 2 different content template seems like a good idea if we can fix the other issue. Kindly check the coach single page and let me know if the image is working correctly. (hidden link)

Thanks for your patience and cooperation

Regards,
Osama

March 18, 2021 at 12:57 pm #8342493

vadimP

Hi,

Yes, the image works now, thank you! Just one other field that isn't loading is in the sidebar - I will include a screenshot. If that can be fixed in EN version as well, then I think this is pretty much a working solution.
(I see that on test site it displays "Loading..." in both RU and EN, but I've also quickly checked on live website - "Loading..." is only an issue in EN version if I'm using this method with 2 separate templates.)

Screenshot 2021-03-18 at 14.53.37.png
March 18, 2021 at 1:04 pm #8342603

Osama Mersal
Supporter

Languages: English (English ) Arabic (العربية )

Timezone: Africa/Cairo (GMT+02:00)

Hi,

I'm glad that the image issue is resolved. I'm not sure if I understand the sidebar issue correctly do you want to delete the string "Loading.." from the template?

Thanks,
Osama