Parameterizing max value of a jQuery ui slider

Posted by Gandalf StormCrow on Stack Overflow See other posts from Stack Overflow or by Gandalf StormCrow
Published on 2010-04-17T14:39:24Z Indexed on 2010/04/17 18:03 UTC
Read the original article Hit count: 285

Filed under:
|
|

I'm trying to create this slider

http://jqueryui.com/demos/slider/#rangemax

Is it possible to parametrize the max value?

For ex:

$("#slider-range-max").slider({
            range: "max",
            min: 1,
            max: maxValue,
            value: 2,
            slide: function(event, ui) {
                $("#amount").val(ui.value);
            }
        });

Is it possible to pass maxValue value, when I click on something? After its been initialized? Not on document ready function, but even after that?

© Stack Overflow or respective owner

Related posts about JavaScript

Related posts about jQuery