Forum Replies Created

Viewing 2 replies - 16 through 17 (of 17 total)
  • Thread Starter m1k3w

    (@m1k3w)

    Hi Kris

    Thanks for answering

    I added the php file via the mu-plugins and then added all the lightbox code/script code into the html field and it works ??

    but i have a few more questions

    first question

    If Forminator doesn’t allow scripts to work by default for security reasons by adding that code am i opening a can of worms by doing this?

    second question

    Ideally the way i would like to implement this script, is the use forminator html fields for the a tags that open the light box but the main bulk of the code on the actual page but this way doesn’t work

    Forminator html form field, there may be multiple html fields but for testing i’m just using one

    <a class="glightbox2" href="/wp-content/themes/divi-child/glightbox/img/large/gm8.jpg" data-glightbox="title: Title 1; description: .custom-desc4; descPosition: left;">info</a> 
    <a class="glightbox2" href="/wp-content/themes/divi-child/glightbox/img/large/gm9.jpg" data-glightbox="title: Title 2; description: .custom-desc5; descPosition: left;">info</a> 
    <a class="glightbox2" href="/wp-content/themes/divi-child/glightbox/img/large/gm9.jpg" data-glightbox="title: Title 3; description: .custom-desc6; descPosition: left;">info</a>

    and then afterward in the body of the page after the forminator short code, ill have the rest of the code

    <div class="glightbox-desc custom-desc6">
    <p>Duis quis ipsum vehicula eros ultrices lacinia. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae</p>
    </div>
    <div class="glightbox-desc custom-desc5">
    <p>Duis quis ipsum vehicula eros ultrices lacinia. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae</p>
    </div>
    <div class="glightbox-desc custom-desc4">
    <p>Duis quis ipsum vehicula eros ultrices lacinia.</p>
    </div>
    
    <script src="/wp-content/themes/divi-child/glightbox/js/glightbox.min.js"></script> 
    
    <script>
    var lightboxDescription = GLightbox({
    selector: '.glightbox2'
    });
    </script>
    • This reply was modified 2 years, 8 months ago by m1k3w.
    Thread Starter m1k3w

    (@m1k3w)

    Thank you so much @wpmudev-support9

    I was hoping there was something like that using min and max but i had discounted it as i can’t seem to type a comma into the calculation box?

    but it looks like you can paste them in

Viewing 2 replies - 16 through 17 (of 17 total)