Xylon
Xylon

Reputation: 471

FlexSlider2 Auto play

I'm using flexslider 2 plugin in my website. When i click on next/prev button, The autoplauy stops working. I tried editing the jquery.flexslider.js file but No use. Can anyone suggest me some solution to this?

Even on the demo website of flexslider2 the autoplay stops if clicked on next/prev button

Upvotes: 1

Views: 9760

Answers (1)

Umesh Sehta
Umesh Sehta

Reputation: 10683

try to add this in jquery code:-

 $('.flex-next').click(function(){ 
    $('.flexslider').flexslider("play") }); 
    $('.flex-prev').click(function(){ 
        $('.flexslider').flexslider("play") 
 });

Demo

Or you can try this:-

$('.flexslider').flexslider({
  pauseOnAction: true, // default setting
  after: function(slider) {
  /* auto-restart player if paused after action */
  if (!slider.playing) {
    slider.play();
  }
 }
});

Demo2

Upvotes: 5

Related Questions