0

So I have made an image slideshow automatic, by auto clicking the next button <.slick-next> every 7 seconds using the code below. I want to know if it is possible to cancel the function if the user clicks either of the buttons <.slick-next><.slick-prev> so then they can scroll through the images themselves rather than it auto changing when the user changes it to an image they want to look at. Also note it is not a button it is a div and i get it by class name!

<script>
setInterval(function () {
$(".slick-next").click();
}, 7000);
</script>

.slick-prev
Asn
  • 113
  • 6

0 Answers0