Hi,
Once prettyPhoto has been disabled, you shouldn’t need to do anything else to lightbox images on the site. If you’re looking to lightbox other content, you’d need to add data attributes to the things that you want to lightbox.
The full listing of data attributes can be found on their GitHub documentation and here’s an example of lightboxing a video on one of our theme demos.
Hope that helps!
Thread Starter
csjWP
(@csjwp)
Hi again,
I’ve added this to my Child Theme functions.php file
function remove_scripts(){
wp_enqueue_script('prettyphoto' );
wp_deregister_script('prettyphoto' );
}
add_action( 'wp_enqueue_scripts', 'remove_scripts', 100 );
And it do disable prettyPhoto from loading. But I’m afraid WP Featherlight isn’t taking over. I just see “large image”.
Is it possible to create a funtion that just calls WP Featherlight where prettyPhoto would normally get called?
Can either of you provide a link to a site where prettyPhoto has been disabled and WP Featherlight is activated but not working? If I can see what the actual issue is I may be able to offer more insight.
If not, the only way I can debug is to test using a copy of Visual Composer on a local site, which I can definitely try but it may take me a while to get to it.
Thread Starter
csjWP
(@csjwp)
Hey Robert, thanks for the reach out and your willingness to assist with this. The site I’m working on I’m afraid is running locally on MAMP. So I don’t have an easy way to share it with you… Unless there are options and tricks i don’t know about. If you want me to do something, please reach out.