Skip Navigation

[Resolved] Translate a view with WPML

This support ticket is created 3 years, 6 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
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10: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/Kolkata (GMT+05:30)

This topic contains 11 replies, has 2 voices.

Last updated by martinG-11 3 years, 6 months ago.

Assisted by: Minesh.

Author
Posts
#2201571

Hi,
I created a view and have it on this page: hidden link

Now I need to have this also in english and polish language. I use WPML for translation but have no idea how to translate the view. Can you assist me here?
Thanks a lot!

#2201719

Minesh
Supporter

Languages: English (English )

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

Hello. Thank you for contacting the Toolset support.

Here is the official Doc that you should try to follow to translate your view:
- https://toolset.com/course-lesson/translating-views-content-templates-archives-and-forms/

#2202953

Hi Minesh,
thanks for your assistance and pointing to the Toolset documentation. Concerning translation of views a read there:

"Translating Views
To send a View for translation, simply send the page where you created the View. Translator that takes the job will have all the View texts available for translation."

This is not true for my view. I created it with the legacy editor. How can I translate this view? Also the view is not working correctly on a translated page. It only shows the search and filter elements but not the view output. Instead "nichts gefunden" (nothing found) is displayed. So what is going wrong here?

hidden link

Thanks for further support!

#2204681

Minesh
Supporter

Languages: English (English )

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

If you are using the legacy view, you can then translate the strings added to your view using the [wpml-string] shortcode:
=> https://toolset.com/documentation/programmer-reference/views/views-shortcodes/#wpml-string

Then, once you localize your strings using the [wpml-string] shrotcode you should navigate to WPML => String Translation and search for your string and translate it to your additional languages.

#2204735

Hi Minesh,
thanks a lot for the help. I was able to translate the strings now.

But I still can't figure out why the view isn't showing any results.

Please have a look: hidden link
and compare with the german version: hidden link

Why has the view loop no output?
Can you please investigate this issue? I can send you a login to a test site. Please enable a private message for this.
Thanks!

#2204753

Minesh
Supporter

Languages: English (English )

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

*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin and FTP) to your site. 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.

I have set the next reply to private which means only you and I have access to it.

#2204949

Minesh
Supporter

Languages: English (English )

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

I see with the post type "publikation", none of the posts are translated to the add-on languages.
=> hidden link

Can you please make sure that you translated all the posts.

More info:
- https://wpml.org/documentation/getting-started-guide/translating-custom-posts/

Please make sure that you setup the WPML and configure WPML correctly. If you require any help with WPML, you are also welcome to create support ticket at: https://toolset.com/forums/forum/professional-support/

#2205115

Thanks again for your assistance!
So, I translated the posts of the type "publikation", but still the view output is empty.

In my case I think it would be best for me to simply embed the original view of the German page and only translate the names of the table columns. Not all posts of the type "publikation" need to be translated, as they are not available in English anyway.

So how can I achieve to display the german view on an english page?

#2205645

Minesh
Supporter

Languages: English (English )

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

In that case I've set the option from "Beitragstypen-Übersetzung" section and selected the option as you can see with the following screenshot: hidden link
=> hidden link

Can you please confirm it works as expected now:
=> hidden link

#2205841
Bildschirmfoto 2021-10-26 um 12.28.56.jpg

Hi Minesh,

yes, I can confirm that it is working. Thanks for your help!

But it is not yet exactly what I want to achieve.

Optimal would be to translate the contents of the custom content type "Publication", but only the description of the fields, not the contents of the fields. See screenshot. Can you show me how this is possible? Thank you very much!

#2205867

Minesh
Supporter

Languages: English (English )

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

As the original question is resolved, as per our support policy we can entertain only one question per ticket.

I urge you to create a new ticket with every new question you may have. This will help other users searching on the forum as well as help us to write correct problem resolution summery.

Thank you for understanding.

#2205869

My issue is resolved now. Thank you!