jquery 滑动改变input值,input隐藏 可以是面积,时间,其他数字等 指定范围
jquery 滑动改变input值,input隐藏 可以是面积,时间,其他数字等 指定范围
XML/HTML Code
- <div class="layout">
- <div class="layout-slider" style="width: 100%">
- Slider <span style="display: inline-block; width: 400px; padding: 0 5px;"><input id="Slider1" type="slider" name="price" value="30000.5;60000" /></span> in string
- </div>
- <script type="text/javascript" charset="utf-8">
- jQuery("#Slider1").slider({ from: 1000, to: 100000, step: 500, smooth: true, round: 0, dimension: " $", skin: "plastic" });
- </script>
- <div class="layout-slider-settings">
- </div>
- <div class="layout-slider">
- <input id="SliderSingle" type="slider" name="price" value="20" />
- </div>
- <script type="text/javascript" charset="utf-8">
- jQuery("#SliderSingle").slider({ from: 5, to: 50, step: 2.5, round: 1, format: { format: '##.0', locale: 'de' }, dimension: ' €', skin: "round" });
- </script>
- <div class="layout-slider-settings">
- </div>
- <div class="layout-slider">
- <input id="Slider2" type="slider" name="price" value="5000;50000" />
- </div>
- <script type="text/javascript" charset="utf-8">
- jQuery("#Slider2").slider({ from: 5000, to: 150000, heterogeneity: ['50/50000'], step: 1000, dimension: ' $' });
- </script>
- <div class="layout-slider-settings">
- </div>
- <div class="layout-slider">
- <input id="Slider3" type="slider" name="area" value="25;75" />
- </div>
- <script type="text/javascript" charset="utf-8">
- jQuery("#Slider3").slider({ from: 0, to: 500, heterogeneity: ['50/100', '75/250'], scale: [0, '|', 50, '|', '100', '|', 250, '|', 500], limits: false, step: 1, dimension: ' m<small>2</small>', skin: "round_plastic" });
- </script>
- <div class="layout-slider-settings">
- </div>
- <div class="layout-slider">
- <input id="Slider4" type="slider" name="area" value="2;10" />
- </div>
- <script type="text/javascript" charset="utf-8">
- jQuery("#Slider4").slider({ from: 1, to: 30, heterogeneity: ['50/5', '75/15'], scale: [1, '|', 3, '|', '5', '|', 15, '|', 30], limits: false, step: 1, dimension: '', skin: "blue", callback: function( value ){ console.dir( this ); } });
- </script>
- <div class="layout-slider-settings">
- </div>
- <div class="layout-slider">
- <input id="Slider5" type="slider" name="area" value="600;720" />
- </div>
- <script type="text/javascript" charset="utf-8">
- jQuery("#Slider5").slider({ from: 480, to: 1020, step: 15, dimension: '', scale: ['8:00', '9:00', '10:00', '11:00', '12:00', '13:00', '14:00', '15:00', '16:00', '17:00'], limits: false, calculate: function( value ){
- var hours = Math.floor( value / 60 );
- var mins = ( value - hours*60 );
- return (hours < 10 ? "0"+hours : hours) + ":" + ( mins == 0 ? "00" : mins );
- }})
- </script>
- </div>
相关推荐
开心就好 2020-06-10
huha 2020-10-16
TLROJE 2020-10-26
echoes 2020-08-20
nercon 2020-08-01
zhanghaibing00 2020-06-28
Aveiox 2020-06-25
henryzhihua 2020-06-21
zhoutaifeng 2020-06-17
liangzhouqu 2020-06-16
TONIYH 2020-06-11
x青年欢乐多 2020-06-06
KyrieHe 2020-06-03
bertzhang 2020-06-02
haokele 2020-05-29
niehanmin 2020-05-28
davidliu00 2020-05-26