Saltar navegación

[Resuelto] Conditional display with taxonomies does not work on translations

This support ticket is created hace 5 años, 4 meses. There's a good chance that you are reading advice that it now obsolete.
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)

Este tema contiene 0 respuestas, tiene 1 mensaje.

Última actualización por maximilianD hace 5 años, 4 meses.

Asistido por: Minesh.

Autor
Mensajes
#1349767

I have a conditional logic to show some text based on taxonomies that are set for a product.

I have tried with both of the following:
[wpv-conditional if="( has_term('bos', 'bereich',null) eq '1' )" ]<span class="einsatzbereich-badge bos">Some Text</span>[/wpv-conditional]

{!{wpv-conditional if="( CONTAINS(#(bereich),'bos') )"}!}<span class="einsatzbereich-badge bos">Some Text</span>[/wpv-conditional]

It works fine in the main language (german) but not on the translations, because the slug of the translations of the taxonomies is different. I would expect that wpml or toolset automatically check the condition in the main language as it does with all other conditions.

Is there a way to fix this without having to insert the translated slugs in the conditional logic?