Saltar navegación

[Resuelto] Conditional in combination with parent

This support ticket is created 4 years, 7 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 -

Zona horaria del colaborador: Asia/Hong_Kong (GMT+08:00)

Este tema contiene 1 respuesta, tiene 2 mensajes.

Última actualización por Luo Yang 4 years, 7 months ago.

Asistido por: Luo Yang.

Autor
Mensajes
#2198773

Hello,

I have this code that works fine

{!{types field='naam-organisatie' item='@organisatie.parent'}!}{!{/types}!}

and now i want alse refer to @organisatie.parent in my conditional code

[wpv-conditional if="( NOT(empty($(facebook))) )"] here the FB logo [/wpv-conditional]

How can I refer to @organisatie.parent in the wpv-conditional?

Thanks!

#2198785

Hello,

I assume we are talking about one-to-many relationship, you can use the item attribute in wpv-condional shortcode, like this:

[wpv-conditional if="( $(facebook).item(@organisatie.parent) ne '' )"]
Here display something if parent post field is not empty
[/wpv-conditional]