Skip Navigation

[Resuelto] Display text on frontend depending of the choice of a multi checkbox field

This support ticket is created hace 5 años, 11 meses. 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.

Hoy no hay técnicos de soporte disponibles en el foro Juego de herramientas. Siéntase libre de enviar sus tiques y les daremos trámite tan pronto como estemos disponibles en línea. Gracias por su comprensión.

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/Karachi (GMT+05:00)

Este tema contiene 2 respuestas, tiene 2 mensajes.

Última actualización por petranL hace 5 años, 11 meses.

Asistido por: Waqar.

Autor
Mensajes
#1163983

I am trying to: Conditionally show text depending on the value of an option of a multi checkbox field.

The solution of this ticket is working: https://toolset.com/forums/topic/conditional-display-depending-on-checkbox-2/ :

[wpv-conditional if="( '[types field='havervlokken' option='2'][/types]' eq '3' )"]
TEST STRING 1
[/wpv-conditional]

but I don't know how to handle the option= in this code generated within the Divi builder :

{!{wpv-conditional if="( $(wpcf-havervlokken) eq '3' )"}!}
TEST STRING 2
{!{/wpv-conditional}!}

I tried to place it in several postions, but without luck.

#1164567

Hi there,

Thank you for contacting us and I'll be happy to assist.

When using the Toolset shortcodes inside the Divi builder, you can replace all opening brackets of shortcodes from "[" to "{!{" and the closing ones from "]" to "}!}".

For example, if this conditional block is working as expected, outside the Divi builder:


[wpv-conditional if="( '[types field='havervlokken' option='2'][/types]' eq '3' )"]
TEST STRING 1
[/wpv-conditional]

Inside the builder, you can update it to:


{!{wpv-conditional if="( '{!{types field='havervlokken' option='2'}!}{!{/types}!}' eq '3' )"}!}
TEST STRING 1
{!{/wpv-conditional}!}

I hope this helps.

regards,
Waqar

#1166204

My issue is resolved now. Thank you!