is it possible to set the default value of a slider between two steps as default (initializing)
$( ".slider" ).slider({
value: 25,
min: 0,
max: 50,
step: 10,
slide: function( event, ui ) {
//$( "#amount" ).val( "$" + ui.value );
},
disabled: false
});
will not work.
i also tried to set the css style to:
.ui-slider-handle {
left: 50%;
}
but the plugin will reset the value
Update
i removed the step option on initializing the slider. after the slider starts sliding i will set the step to 10 this will be the desired result
$( ".slider" ).slider({
value: 25,
min: 0,
max: 50,
start: function( event, ui ) {
$(this).slider("option", "step", 10);
},
slide: function( event, ui ) {
},
disabled: false
});
Update 2
this solutions stucks if i drag the handler one step to the right, it jumps to the second step on the right side. any explanation on this behavior?