Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

Get value from ionRangeSlider in jquery

var $range = $(".js-range-slider"),
    $inputFrom = $(".js-input-from"),
    $inputTo = $(".js-input-to"),
    instance,
    min = 0,
    max = 1000;

$range.ionRangeSlider({
    type: "double",
    min: min,
    max: max,
    from: 100,
    to: 900,
    onStart: updateInputs,
    onChange: updateInputs,
    onFinish: updateInputs
});

function updateInputs (data) {
    $inputFrom.prop("value", data.from);
    $inputTo.prop("value", data.to);
}

instance = $range.data("ionRangeSlider");
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #Get #ionRangeSlider #jquery
ADD COMMENT
Topic
Name
4+7 =