0

Here is what I tried, but it did not work:

var $slider = jQuery( "#slider" );
$slider.slider("option", "min", min_range);
$slider.slider("option", "max", max_range);
spenibus
  • 4,339
  • 11
  • 26
  • 35
Adi Dynaweb
  • 69
  • 1
  • 12
  • getting any `js` error? otherwise this code should work. can you please post entire js code with HTML. – vijayP Oct 09 '15 at 11:26
  • No error.. But i fixed it by destroying the slider and then re-initialize it. Thank you for your precious time. – Adi Dynaweb Oct 12 '15 at 04:46

1 Answers1

0

I found the fix. When clicked on button i destroyed the slider and then re-initialized it with new range values.

Here is the code:

 jQuery("#slider").slider("destroy");
 jQuery("#slider").slider({
            range: true,
            min: new_min_range,
            max: new_max_range,
            values: [ new_min_range, new_max_range ]
});
Adi Dynaweb
  • 69
  • 1
  • 12