jQuery UI Slider - Value returned from 'slide' event on release is different from 'change' value

前端 未结 4 2024
小蘑菇
小蘑菇 2020-12-19 04:27

I have a jQuery UI slider:

$(\'div.slider\').slider({
    range: true,
    step: 250,
    min: 1000,
    max: 500000,
    values: [1000,500000],
    change:          


        
4条回答
  •  甜味超标
    2020-12-19 04:52

    Your min, max and step values look a bit weird, but I guess you just got them mixed up.

    I found that the slider doesn't work too well with steps much smaller than 1, so I changed to use integers only and divide afterwards. Never had any problems since then.

提交回复
热议问题