特效描述:jQuery 可选择区间值。jQuery可选择区间值代码
代码结构
1. 引入CSS
2. 引入JS
3. HTML代码
$(document).ready(function () {
var $range = $("#range_44"),
$result = $("#result_44");
var track = function (data) {
delete data.input;
delete data.slider;
if (JSON) {
$result.html(JSON.stringify(data, null, 2));
} else {
$result.html(data.toString());
}
};
$range.ionRangeSlider({
type: "double",
min: 0,
max: 500,
from: 100,
to: 300,
step: 50,
grid: true,
onStart: track,
onChange: track,
onFinish: track,
onUpdate: track
});
});