채택완료

스와이프 슬라이드 관련

2017-12-30 (토) 22:37:27 2,408
Copy
<script>
    var swiper = new Swiper('.swiper-container', {
      slidesPerView: 1,
      spaceBetween: 0,
      loop: true,
      autoplay: {
        delay: 10000,
      },
      pagination: {
        el: '.swiper-pagination',
        clickable: true,
      },
      navigation: {
        nextEl: '.swiper-button-next',
        prevEl: '.swiper-button-prev',
      },
    });
  </script>

스와이프 슬라이드 입니다.

롤오버시 정지시킬려면 어떻게 해야하나요?

autoHover 이것도 안 먹히더라구요ㅠㅠ

|

답변 1개

채택된 답변
+20 포인트
2017-12-30 (토) 22:48:09
Copy
$('.swiper-slide').on('mouseover',function() { swiper.stopAutoplay(); });

$('.swiper-slide').on('mouseout',function() { swiper.startAutoplay(); });

답변을 작성하려면 로그인이 필요합니다.