Is there a way to limit the slider options in jQuery UI slider?
I have a slider that is broken up into 5 parts.
However, I only want options 2,3, and 4 available. I don’t want the handle to go to 1 or 5.
how do you restrict this?
Thanks!
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can listen to the slide event and test for it’s position.
When it’s at 1 or 5, you can
return falseand cancel the event.This seems to work
Have a play here.