Badea Sorin
Badea Sorin

Reputation: 174

SlidesJS Slide Id

I'm using SlidesJS for a custom products gallery and I have trouble id-ing the current slide. I've used animationStart:function(current) but when i use navigation is not accurate. The scope of all this is to get some content from the caption of the current slide.

Thanks, Sorin!

Upvotes: 0

Views: 1559

Answers (1)

zeantsoi
zeantsoi

Reputation: 26203

Per the SlidesJS documentation for animationComplete():

  $("#slides").slides({
    animationComplete: function(current) {
        console.log(current); // Log the current slide number to the console
    }
  });

Upvotes: 1

Related Questions