Reputation: 471
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
Reputation: 10683
try to add this in jquery code:-
$('.flex-next').click(function(){
$('.flexslider').flexslider("play") });
$('.flex-prev').click(function(){
$('.flexslider').flexslider("play")
});
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();
}
}
});
Upvotes: 5