Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
jQuery to create Lightbox popup using Oxygen's Modal element
jQuery('.lightbox-trigger').click( function() {
var image = jQuery(this).attr('src');
jQuery('.lightbox-popup').css('background-image', 'url(' + image + ')');
var caption = jQuery(this).next().text();
jQuery('.lightbox-popup-caption').text( caption );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment