Skip Navigation

[Resolved] Translate with WPML some specific Toolset field and content type

This support ticket is created 4 years, 8 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

This topic contains 18 replies, has 3 voices.

Last updated by Vane 4 years, 8 months ago.

Assisted by: Luo Yang.

Author
Posts
#1543597

Hi,

I set up a site with EN default language (having this best practice, installing all themes and plugins with EN default) and set up some Toolset CPTs, custom taxonomies, templates, fields, views and CRED forms and when all worked properly in EN, I changed my WPML default language to HU.
I used [wpml-string] shortcode where needed and I translated strings where it was possible.
I have issues though in translating field strings in

- Heading
- Fields and Text
types.

How can I translate those strings?

Thank you!

#1544163

Hello,

I assume we are talking about in Toolset Blocks plugin, those two blocks:
- Heading
- Fields and Text

You can translate them like this: Dashboard-> WPML-> String Translate:
Search and translate those text in above blocks.

The string domain name should be "gutenberg-{post-ID}".

#1544169

Hi,

no, I prefer Views, Blocks has some limitations.
Though I use block editor in content templates and views where possible.

How to do in this case?

Thank you

#1544175

It should be the same process in Views or Blocks plugin, you can translate them here: Dashboard-> WPML-> String Translate:
Search and translate those text in those blocks.

#1544183

I suppose I clearly wrote in my OP that there's no such strings in String translation area

"I used [wpml-string] shortcode where needed and I translated strings where it was possible."

#1544189

It is abnormal, I have tried it in my localhost with a fresh WordPress installation + the latest version of Toolset plugins + WPML plugins, it works fine, I can translate the text of both blocks into other languages:
- Heading
- Fields and Text

And it does not need shortcode [wpml-string].

Please check these it in your website:
1) Make sure you are using the latest version of Toolset + WPML plugins, especially the WPML plugins,

2) In case it is a compatibility problem, please deactivate all other plugins, and switch to wordpress default theme 2020, deactivate all custom PHP/JS code snippets, and test again

3) If the problem still persists, please provide database dump file(ZIP file) of your website, also point out the problem post URL, I need to test and debug it in my localhost, thanks
https://toolset.com/faq/provide-supporters-copy-site/

#1544291

Pls. check these 2 pages:
hidden link
where
"Related posts:" should be translated.
It is a Heading type in a content template.
In WPML an exact match string exists with domain:
gutenberg-161
and it's been translated days ago.

Another page:
hidden link
where there are 2 Text and Field type content in another content template, namely:
Related Brand: AQUA
Context: Minőség, Ügyfélszolgálat
where the 2 English parts are the text parts of the field and those should be translated.
I re-checked and neither
"Context:" ( with or without ":", tried with both exact and non-exact martch )
nor
"Related Brand:" ( with or without ":", tried with both exact and non-exact martch )
been found as not translated or wrongly marked as translated. ( I checked all )

I rescanned both Views and CRED ( added about 5700 more strings into db ) but I haven't found another instances of the strings.

Maybe related: pls. note I'm not able to update my WP HU translation, it looks completed but it still shows it is still available for update.
"WordPress 5.3.2–hu_HU"
I tried it after multiple hard reload, even after log out and re-log in.

If you don't have another idea after this, I'll continue with your 2 and 3 ( 1 is obviously done ),
pls. switch it back to me in private.

#1545209

The URLs you mentioned above is missing domain name, so I can not check anything, please continue with 2 and 3, private message box enabled again.

#1545435

Thanks for the details, I can login your website, those texts you mentioned above are setup in content templates, so you will need to follow our document to translate the content templates:
https://toolset.com/documentation/translating-sites-built-with-toolset/translating-content-templates-wordpress-archives-and-views/

#1545493

There were so many tabs on the right and Language tab is below fold ( on a 27" monitor ), so I simply haven't seen it... :-/

Could you check the following:
If you edit my content template named:
Template for Brands,
you can see its bottom another content template named:
Brand Post Form Template,
which can not be found in either
Toolset / Dashboard or / Content Templates.
( I know I can edit that from there, but Dashboard and Content Template page is very useful - if it shows every each items correctly )

I think it was shown and available from there, when either EN was the default language or with an earlier version.
Also, this Content Template page, Name tab: it shows
5 published,
but it only lists 2 in fact, even if I check all other tabs there.
( I may think 2 EN + 2 HU (of the displayed CTs) + Brand Post Form Template EN equals 5),
but this is totally misleading this way...

Pls. note I don't use Translation Management, because:
a) I supposed I don't need and I wanted to speed up my site
b) it sends out emails with admin usernames ( not nicename or display name ) what I hate.

Thank you

#1546455

For the new question, the content template "Brand Post Form Template" is a content template block of content template "Template for Brands".

I have tried it in my localhost, with below steps:
1) Create a content template "CT A"
2) Create the content template "CT B", add a content template block, choose "CT A".
And both content templates should be in the lists: Dashboard-> Toolset-> Content templates

How do you setup/create the content template "Brand Post Form Template", please provide detail steps to duplicate the same problem, thanks

#1546551

I simply created a new CT and didn't add it to any CPT.
That time EN was the default language, I later changed it to HU, as explained in OP !

As you can see it is included in both
Template for Brands
and
Template for Brand Posts
( it adds a conditional display of "Login to Create a New Post / Create a New Post / Edit a Post link with the appropriate link, maybe doesn't work now in HU, but I hope I can fix it, so no need for help in that topic ).

So when you try to replicate, start with EN and later switch to secondary language.
Also, how do you explain that
"5 published" ?

#1546679

The same appears if I use theme 2020 and most of the plugins except WPML and Toolset are deactivated.

Pls. note that at
Toolset / Content Templates / Name
the column "Used on" shows incorrectly:
"No Post types/Taxonomies assigned"
( obviously the first is assigned to Brand Posts and the 2nd to Brands CPT )

If you can't replicate it or have a fix, pls. allow me my next response to be private, I do #3 Duplicator or db dump.

#1548265

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Luo is having a holiday today. He will get in touch with you tomorrow as soon as he will be back to work.

#1549433

Private message box enabled, please provide the database dump file, thanks