#3004 closed bug (fixed)
Change slider options from range to single value on the fly
Reported by: | Kyle | Owned by: | paul |
---|---|---|---|
Priority: | major | Milestone: | 1.5.1 |
Component: | ui.slider | Version: | 1.5 |
Keywords: | slider, range | Cc: | |
Blocked by: | Blocking: |
Description
I am trying to use the slider in two, exclusive ways. In one instance, I want a range of values to search for. In the other instance, I want to search for a single value. I want one slider to do this and to use a checkbox to toggle range:true and range:false.
This is my attempt to change an already-set slider that functions perfectly.
$("input[name=rangeLSAT]").bind("click",function(){
if($(this).attr("checked")){
Now it's checked
} else{
Now it's unchecked $("#LSAT_Slider").slider({
range: false, slide: function(e,ui) {
alert("Hi");
}
});
}
It produces the following error:
d.split is not a function e(Object range=false, undefined)jquery-1.2.6.pack... (line 11) (no name)()0708 (line 67) e(Object originalEvent=Event click which=1 view=window)jquery-1.2.6.pack... (line 11) e()
The initial initiation of the slider works flawlessly.
Change History (3)
comment:1 Changed 15 years ago by
comment:2 Changed 15 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
Hey there, you are doing it the wrong way, but non-the-less, it needed some implementation. In the lastest revision (or 1.5.1), you can now do
$(..).data("range.slider", false)
to disable the slider option for the selected slider (same with later enabling it again).
comment:3 Changed 15 years ago by
Milestone: | → 1.5.1 |
---|---|
Version: | 1.5b4 → 1.5 |
Oops, I posted the wrong error.
The correct error is:
C.data("mouse") has no properties e(undefined, "x")jquery-ui-1.5-sli... (line 1) e(Object originalEvent=Event mousedown which=1 view=window, div#LSAT2.ui-slider-handle)jquery-ui-1.5-sli... (line 1) e(Object originalEvent=Event mousedown which=1 view=window)jquery-ui-1.5-sli... (line 1) e(Object originalEvent=Event mousemove which=1 view=window)jquery-ui-1.5-sli... (line 1) e(Object originalEvent=Event mousemove which=1 view=window)jquery-ui-1.5-sli... (line 1) e(Object originalEvent=Event mousemove which=1 view=window)jquery-1.2.6.pack... (line 11) e()
This error occurs only after I click the checkbox, instantiating the slider option change, when I try to drag one of the handles.