archetyped / simple-lightbox-extensions

Feedback & Support for Simple Lightbox Extensions
https://archetyped.com/tools/simple-lightbox/
2 stars 3 forks source link

[Video / Issue]: Advanced Custom Fields & Simple lightbox Video Add-on #75

Closed shopowner58 closed 5 years ago

shopowner58 commented 5 years ago

Description of issue

Hi, I want to use the video lightbox on a portfolio page. I am using ACF. my custom field is <?php the_field( 'video_url' ); ?> This gives the following result: https://www.youtube.com/watch?v=XzTCntGgNJU How can I implement the code in my single-portfolio.php file?

This is not working <p><a href="<?php the_field( 'video_url' ); ?>" data-slb-active="1" data-slb-asset="1" data-slb-group="1">open video</a></p> Can you please tell me how to fix this issue?

Details

archetyped commented 5 years ago

Hi, manually adding SLB-specific attributes to a link will generally not do anything as they are primarily meant for internal use.

You can manually activate a link with the slb_activate() template tag. See SLB's documentation on manual link activation for more details and example code.