Here is the initialization

$slyWrapp = $(".sly_block_wrapp"); $frame = $slyWrapp.find(".sly_block"); var $slidee = $frame.children('slide').eq(0); var $wrap = $frame.parent(); sly = new Sly($frame, { horizontal: 1, itemNav: 'basic', smart: 1, activateOn: 'click', mouseDragging: 1, touchDragging: 1, releaseSwing: 1, startAt: 1, scrollBar: $slyWrapp.find(".scrollbar"), scrollBy: 1, activatePageOn: "click", speed: 300, elasticBounds: 1, dragHandle: 1, dynamicHandle: 1, clickBar: 1, prev: $wrap.find('.prev_sly'), next: $wrap.find('.next_sly') }).init(); 

How to find out the index of the active slide when loading and changing slides?

  • $('.активный-класс').index('.класс-всех-слайдов'); - Such a thing will determine the index of the active class. Provided that you have classes there on the slider ... jsfiddle.net/OPTlMUS/9kx1h2j3 - a demo (although here you have added a selector of two classes, so you probably should just click on the desired active class, not on any page) - OPTIMUS PRIME

0