Jssor(嵌套滑块):如何禁用自动播放? [英] Jssor (nested slider): how to disable AutoPlay?
问题描述
有人知道如何防止嵌套滑块在加载时启动吗?我尝试在"var nestedSliderOptions"中输入"$ AutoPlay:false",但是它不起作用.预先感谢.
Does anyone know how to prevent the nested slider to start upon loading? I've tried entering "$AutoPlay: false" inside "var nestedSliderOptions", but it doesn't work. Thanks in advance.
来源: http://www.jssor.com/download.html examples-jquery> nested-slider.source.html
source: http://www.jssor.com/download.html examples-jquery > nested-slider.source.html
推荐答案
默认情况下,主滑块和3个子滑块没有自动播放"功能.它是通过手动API调用控制的.
There is no 'auto play' for the main slider and 3 child sliders by default. It is controlled by manual API call.
通过删除以下代码,您将获得所需的内容.
By removing following code, you will get what you want.
function OnMainSliderPark(currentIndex, fromIndex) {
$.each(nestedSliders, function (index, nestedSlider) {
nestedSlider.$Pause();
});
setTimeout(function () {
nestedSliders[currentIndex].$Play();
}, 2000);
}
jssor_slider1.$On($JssorSlider$.$EVT_PARK, OnMainSliderPark);
OnMainSliderPark(0, 0);
网格滑块是嵌套滑块的一种变体.
Also, the grid slider is a variation of nested slider.
这篇关于Jssor(嵌套滑块):如何禁用自动播放?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!