[Résolu] Custom Post type is translated but doesn't get filtered by page language
This support ticket is created Il y a 2 années et 9 mois. 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.
No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.
I am trying to:
my "comunicati stampa price sensitive" are a CPT with a non-translated taxonomy. They are translated (mostly) but on the Italian Page even the english translations show up
Link to a page where the issue can be seen: hidden link
I expected to see:
only the italian ones on this page and only the english ones on this hidden link
page
Instead, I got:
both IT and EN posts on the Italian page.
WPML support told me to get your support cause they can't find the problem in your filters.
Hello and thank you for contacting Toolset support.
I don't think that WPML allows to translate posts and keep categories non translated. Can you share with me the WPML support ticket so, I can check what the support team has tried with you.
AFAIK, if you are translating posts, the taxonomies need to be translated too.
Point is, i also translated the custom taxonomies, but nothing changed.
I believe that, because i'm using a WP-view (view-tabella-comunicati-stampa-price-sensitive) inside a page.
This view has a repeater fields view inside (view-repeatable-fields).
I guess I need to force the loop to be in the language of the page
Sorry I can't edit my answer.
The previous code is the Repeater Field View. I think I need to force this to check if the language of the CPT matches the one from the page.
As I explained in my previous reply, if you are translating posts, you must translate the taxonomies too.
Currently, the taxonomy is not translatable. Check this screenshot hidden link
Even though, the terms are duplicated, probably because of a previous translation. The slugs let me think so.
So, I changed the configuration for the taxonomy, and yes, it was translated before, and the terms are linked across languages.
The view on the other hand does return the correct posts. As you can see in this screenshot, the Italian page returns the Italian posts, and the English page returns the English posts. Check the IDs from the screenshot hidden link
The issue is that the repeatable fields are duplicated in both languages. Check this screenshot hidden link
So, I'll suggest that you remove the repeatable field group item that does not patch its language. Or retranslate the posts.
I'll remain at your disposal.
This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.