We have a lot of slides in our slideshows and our users would like to know which one they are on. So, I want to display something like “1/30” ,“12/30” or “30/30” . I’d like to use the “after” callback to update my counter. The after callback works fine except I have been unable to find a way to access the FlexSlider’s internal information to determine which slide is the currently active slide. I know FlexSlider knows which one is active because it puts the “flex-active-slide" class on the active slide.
I suppose could inspect the DOM to find the slide that has the “flex-active-slide" class on it and then figure out which one it is but, that feels really wrong.
Is there a way to get FlexSlider’s status information via the “after” callback? WooThemes documentation for FlexSlider mentions a “slider.vars” variable that might have this info but I can’t seem to access it.
You should be able to access a $slider local in the expression of the "after" callback. From that you should have all you need to get to the flexslider internals.
We have a lot of slides in our slideshows and our users would like to know which one they are on. So, I want to display something like “1/30” ,“12/30” or “30/30” . I’d like to use the “after” callback to update my counter. The after callback works fine except I have been unable to find a way to access the FlexSlider’s internal information to determine which slide is the currently active slide. I know FlexSlider knows which one is active because it puts the “flex-active-slide" class on the active slide.
I suppose could inspect the DOM to find the slide that has the “flex-active-slide" class on it and then figure out which one it is but, that feels really wrong.
Is there a way to get FlexSlider’s status information via the “after” callback? WooThemes documentation for FlexSlider mentions a “slider.vars” variable that might have this info but I can’t seem to access it.