Explanations in this text is based on a example where minimum range value is 40 and maximum is 60. http://jsfiddle.net/77SsQ/4/
Situation
I have a UI range slider (see code below text) that have two values, one for minimum (left handlebar) and one for maximum (right handlebar). This result in a fixed range of numers to search, one minimum number and one maximum number.
Missing features
I want to be able to set unlimited minimum and maximum values, so when the left handlebar is set to 40 it search for all results with value 40 and below, and when the right handlebar is set to 60 it search for all results with value 60 and above. This means that if a visitor set the left handlebar to 50 (middle of slider), and the right handlebar to maximum, it will search for all values above.
In the code is not such of a problem becuse all results under 40 can be set to 40 and all over 60 can be set to 60, so when the handlebar is set for example 60 its search for all values over 60.
Problem
The problems is the labels, the visible part of the slider. All numbers between 41 and 59 should be just as usual, but when the left handlebar is set to 40 it should show "40 or less" and when the right handlebar is set to 60 it should show "60 or more".
Now the slider acts like I want (at jsfiddle page) but now it dont show up in the page becuse its not getting initialized/executed (I guess) becuse its get loaded in from another page.
This is how the code to a functioning slider in page looks like:
not entirely sure that I understand the problem, but does this help?
No that dident help but I will try to explain the problem better. The slider is placed in a div in a external page (example Page2 #2) and this content gets loaded via jQuery to a div (example #div1) in Page1 based on choises in a select-dropdown. The select alternatives look kinda like this:
mmm.., I guess you would have to explain what you mean by initialize, and maybe what is the advantage in having the slider on another page, rather than just in a hidden div, and I guess really what exactly is going wrong and what you expect to happen....
mmm.., I guess you would have to explain what you mean by initialize, and maybe what is the advantage in having the slider on another page, rather than just in a hidden div, and I guess really what exactly is going wrong and what you expect to happen....
I think I soon will try to execute the load-in-content with .live() function insteed.
The sliders is in a different page and gets loaded in to a div (based on choice in a dropdown different content will be loaded) becuse the content with the sliders is much code so its not necessary to have it loaded at pageload if the content is not used.