Site logo

[Resolved] Multiple Gliders

Home Forums Support [Resolved] Multiple Gliders

Home Forums Support Multiple Gliders

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #1799315
    melvin

    Hi Tom/David,

    This might be off the support topic, I’ve tried to solve by few days but still fail. Thats why I come to seek if you could help. I’m using glider.js on this test page and it’s very succesful.

    The issue now is I tried to use 3 gliders on the same page, the 2nd and 3rd gliders do not function properly. Tried google it has come to 2 possible solutions, which is run a loop over HTMLcollection or using forEach method.

    Nonetheless, my self-learning knowledge limit me to execute the 2 possible solutions. Thus would you be kind enough to let me know what code should I hook into wp_footer to make multiple gliders working in a same page?

    Currently this is the code I used to initiate the Glider

    <script>
    window.addEventListener('load', function(){
    
    new Glider(document.querySelector('.glider'), {
      slidesToShow: 1.2,
    	slidesToScroll: 1,
      dots: '#dots',
      arrows: {
        prev: '.glider-prev',
        next: '.glider-next'
      },
    	responsive: [
        {
          // screens greater than >= 775px
          breakpoint: 775,
          settings: {
            slidesToShow: 1.9,
            slidesToScroll: 1,
          }
        },{
          // screens greater than >= 1024px
          breakpoint: 1024,
          settings: {
          }
        }
      ]
    });
    });
    </script>

    Thanks in advance.

    Regards,
    Melvin

    #1799384
    Leo
    Staff
    Customer Support

    Hi Melvin,

    Unfortunately we cannot help with custom solutions like this in the support forum here – need to keep it fair for everyone.

    Can you try a general forum like this?
    https://wordpress.stackexchange.com/

    Thanks for your understanding.

    #1799405
    melvin

    Hi,

    Noted with thanks.

    Regards,
    Melvin

    #1799556
    Leo
    Staff
    Customer Support

    No problem 🙂

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.