本文介绍了Jssor非jquery滑块。一页上有多个滑块的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
有没有办法在一个页面上放置多个滑块?
谢谢
Is there way to put multiple sliders on a single page?Thank you
推荐答案
在一个页面中给出2个滑块,第一个是'slider1',第二个是'slider2 '
Given 2 sliders in one page, the first is 'slider1', the second is 'slider2'
<script>
jssor_slider1_starter = function (containerId) {
...
};
jssor_slider2_starter = function (containerId) {
...
};
</script>
<div id="slider1_container" style="position: relative; top: 0px; left: 0px; width: 600px;
height: 300px;">
...
<script>
jssor_slider1_starter('slider1_container');
</script>
</div>
<div id="slider2_container" style="position: relative; top: 0px; left: 0px; width: 600px;
height: 300px;">
...
<script>
jssor_slider2_starter('slider2_container');
</script>
</div>
这篇关于Jssor非jquery滑块。一页上有多个滑块的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!