Using the bootstrap slider, I am trying to configure a way to assign a value to the handle from another variable. Although I came across a method that uses the data-slider-value attribute for this purpose, it did not work for me.
<input id="gravite" name="gravite" type="text"
data-provide="slider"
data-slider-ticks="[1, 2, 3]"
data-slider-ticks-labels='["Low", "Medium", "High"]'
data-slider-min="1"
data-slider-max="3"
data-slider-step="1"
data-slider-value=""
data-slider-tooltip="hide" />
Javascript
var value = $(this).attr('gravite');
$("#gravite").slider('setValue', value);