Your Cart

Prevent Lightbox when clicking Button on LAYER

These forums are now closed to new replies / tickets.

Please open a support ticket from our new Support page.

Front Page Forums Questions Prevent Lightbox when clicking Button on LAYER

  • gravatar
    October 4, 2014 at 8:03 pm


    I have lightbox enabled on galleria, however , i also have some
    buttons placed on top of galleria layer with :‘.galleria’, {
    dataConfig: function(img) { return { layer:
    jQuery(img).next(‘div’).html() } } });

    where HTML content is (some styles amended , so short version)


    and JS code to fire on “rateme” class is :

    $(document).on(“click”,”.rateme”, function(event) { //
    event.stopPropagation(); //tried this // event.preventDefault();
    //tried this alert(‘TESTING’);


    Idea is – there is a small square box for rating, but when I
    click it , instead of doing what i need it also fires a lightbox in
    parallel. How can I prevent lightbox from showing up when click is
    done on rating box ?

    1. lightbox

    October 4, 2014 at 8:05 pm

    Oh, I see HTML didnt render correctly , where I tried to
    describe my HTML of the box itself, but ithink you’ve got my point
    from the image

    August 23, 2015 at 12:51 pm

    Hi, I have now the same problem. If I click on the layer with
    the link, it also open the lightbox. I’m using JSON to serve data.
    How can I get out of it?

    var data = [
            thumb: '',
            image: '',
            big: '',
            layer: '<div><h2>VEN01</h2><h6><a href="javascript:toggleCheck('VEN01')">Add to cart</a><h6></div>',
            layerFollow: 'true'
    1. Cart

Galleria uses cookies to provide necessary site functionality. By using our website, you agree to our Privacy Policy. I understand