What I basically have now:
I have a portfolio gallery masonry grid (using JIG plugin) that queries my custom post_type.
For each post, clicking on the thumbnail will trigger a lightbox showing the photo.
JIG allows you to use many different lightbox versions (
PrettyPhoto, JP Carousel, ColorBox , PhotoSwipe), The lightbox’s can be configured to display descriptions, captions, authors, dates & times, alt text, and a few more fields from within JIG itself.
The desired goal:
- In the lightbox, I want to display an audio player, and pulling its src from the current post shown just as if it were a title, alt text, or caption field.
- I’ve setup the frontend add new post form for it to accept a mp3 url which saves the url to the mp3 in “my_meta_field”…
- I use the shortcode which injects the url into the markup. Defaults to the current post, but can be configured to accept $parent_post, or any other variable.
Methods I’ve tried using to call the field from shortcode and standard methods.
types field="my_meta_field"] or
echo types_render_field( "my_meta_field", array("output" => "raw") or
What’s the most straightforward, and simple way to get the