Problem:
¿Cómo mostrar campos solo cuando tienen un valor?
Solution:
Se puede probar si un campo tiene valor antes de que muestra el valor.
P.j. si quieres comprobar que un campo de Types "descripcion" tiene valor, se hace así:
[wpv-conditional if="( NOT(empty($(wpcf-descripcion))) )"] <p>Descripción: [types field="descripcion"][/types]</p> [/wpv-conditional]
Relevant Documentation:
https://toolset.com/documentation/user-guides/conditional-html-output-in-views/
https://toolset.com/documentation/user-guides/conditional-html-output-in-views/checking-fields-and-other-elements-for-emptynon-empty-values/
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.
Our next available supporter will start replying to tickets in about 7.45 hours from now. Thank you for your understanding.
Sun | Mon | Tue | Wed | Thu | Fri | Sat |
---|---|---|---|---|---|---|
- | 7:00 – 14:00 | 7:00 – 14:00 | 7:00 – 14:00 | 7:00 – 14:00 | 7:00 – 14:00 | - |
- | 15:00 – 16:00 | 15:00 – 16:00 | 15:00 – 16:00 | 15:00 – 16:00 | 15:00 – 16:00 | - |
Supporter timezone: Europe/London (GMT+00:00)
This topic contains 1 reply, has 2 voices.
Last updated by 6 years, 10 months ago.
Assisted by: Nigel.