Skip Navigation

[Resolved] Conditional Logic Trying to Show a Label if a Field is Polulated

The Toolset Community Forum is closed, for technical support questions, please head on to our Toolset Professional Support (for paid clients), with any pre-sale or admin question please contact us here.
This support ticket is created 10 years, 10 months ago. There's a good chance that you are reading advice that it now obsolete.
This is the community support forum for Types plugin, which is part of Toolset. Toolset is a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients and people who registered for Types community support can post in it.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 19:00 10:00 – 19:00 10:00 – 19:00 10:00 – 19:00 10:00 – 19:00 -
- - - - - - -

Supporter timezone: Europe/Madrid (GMT+01:00)

This topic contains 2 replies, has 2 voices.

Last updated by Alan 10 years, 10 months ago.

Assisted by: Caridad.

Author
Posts
#102591

Hi. I'm trying to show a line of text if one of my custom fields has an image in it so that the text on the site reads as: "Use this password when prompted: password"
I've tried this expression and it doesn't give me the text in-between the two conditions:

[wpv-if field="imagefield" evaluate="!empty($field)"] Use this password when prompted: [types field="passwordfield"][/types][/wpv-if]

Thanks for any suggestions on how I should properly write this expression. -ab

#102756

Dear Alan,

For the wpv-if shortcode you need to use the wpcf- prefix, like this:

[wpv-if field="wpcf-imagefield" evaluate="!empty($field)"] Use this password when prompted: [types field="passwordfield"][/types][/wpv-if]

Please let me know if you are satisfied with my answer and if I can help you with any other questions you might have.

Regards,
Caridad

#102786

Worked like a charm this time. Thanks for your help!

The forum ‘Types Community Support’ is closed to new topics and replies.

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.