Skip Navigation

[Resolved] Photo not showing with embedded media

This thread is resolved. Here is a description of the problem and solution.

Problem:

The issue here is that the user wanted to check if a custom field is empty.

Solution:

To check if a custom field is empty I would recommend following the instructions in the link below.
https://toolset.com/documentation/user-guides/conditional-html-output-in-views/checking-fields-and-other-elements-for-emptynon-empty-values/

This support ticket is created 6 years 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 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 -
- 13:00 – 18:00 13:00 – 18:00 13:00 – 18:00 14:00 – 18:00 13:00 – 18:00 -

Supporter timezone: America/Jamaica (GMT-05:00)

This topic contains 4 replies, has 2 voices.

Last updated by MelodyT7638 6 years ago.

Assisted by: Shane.

Author
Posts
#1196786
Screen Shot 2019-02-06 at 10.18.12 AM.png

We are using the Toolset to present a locations page that has multiple homes with individual pages. I used the embedded media to publish a video for each page. Unfortunately, some pages do not have videos yet, so we are hoping to use a photo as a placeholder until we get videos.

I thought the embedded media would allow me to upload photos as well, but is it just for videos? I also tried inputting the image and it didn't look right (it was pulling the bottom row up).

To view the site:
username/password: flywheel/beaconserv

The page with the successful embedded media: hidden link
The page with the embedded media URL but not showing in frontend: hidden link

Attached you will find a screenshot of the values in the backend.

#1196876

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Melody,

Unfortunately not the this will only allow for videos only.

What you can do is to use our conditional shortcode to check if the field is empty and display an image if it is.

Take a look at the link below to see how you can check if a Types custom field is empty.

https://toolset.com/documentation/user-guides/conditional-html-output-in-views/checking-fields-and-other-elements-for-emptynon-empty-values/

Please let me know if this helps.

Thanks,
Shane

#1197349

Shane, can you help me figure out how to add this conditional shortcode? Where does it go? How do I install it?

#1197356

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Melody,

Sure no problem.

For you scenario you will do it like this.

{!{wpv-conditional if="( empty($(wpcf-vimeo)) )"}!}

Image shortcode goes here 

{!{/wpv-conditional}!}

{!{wpv-conditional if="( NOT(empty($(wpcf-vimeo))) )"}!}

Vimeo Shortcode goes here

{!{/wpv-conditional}!}

Please try this and let me know if this was able to assist you.

Thanks,
Shane

#1197386

My issue is resolved now. Thank you!