<link rel="stylesheet" href="./css/jquery.range.css">


<div class="ip-son">
<div class="demo">
<input type="hidden" class="single-slider3" value="0"/>
<div class="demo-son2">
<input type="text" class="ipgs" value="0">
</div>
</div>
</div>

<script src="./js/jquery.range.js"></script>
var test;
//ip个数
test = $('.single-slider3').jRange({
//滑块滑动时 触发的函数
onstatechange: function () {
$('.ipgs').val($('.single-slider3').val());
},
from: 0,//最小值
to: 1000,//最大值
step: 20,//步进
//这里改变值
scale: [0, 250, 500, 750, 1000],
format: '%s',
width: 500,//总宽度
showLabels: true,
showScale: true
});
$(".ipgs").blur(function () {
test.setValue( $(this).val());//能绑定滑块的变化
});

jquery.range.js 滑块

这里是设置函数绑定滑块的变化

jquery.range.js 滑块

return result || this 改成return result || this.data('plugin_' + pluginName);

 
                    
            
                

相关文章:

  • 2021-06-21
  • 2021-11-22
  • 2021-06-14
  • 2021-08-19
  • 2022-12-23
  • 2021-10-25
  • 2022-12-23
  • 2021-04-06
猜你喜欢
  • 2021-11-04
  • 2022-02-23
  • 2021-04-29
  • 2021-12-05
  • 2021-08-27
  • 2022-01-16
  • 2021-06-30
相关资源
相似解决方案