Reputation: 787
I have the following
min = 1000;
jQuery('#slider').slider({
range: "max",
value: 9000,
min: 1000,
max: 1000000,
step: 500,
});
All I want to do is simply pass the variable "min" into it. Whatever I have tried hasn't worked:
min = 1000;
jQuery('#slider').slider({
range: "max",
value: 9000,
min: min,
max: 1000000,
step: 500,
});
Any ideas?
Upvotes: 0
Views: 538
Reputation: 38147
Here is a jsfiddle - http://jsfiddle.net/manseuk/b58Yd/
I have added var
before your variable declaration and removed the final comma from the list of arguments ....
var min = 1000;
$('#slider').slider({range: "max",
value: 9000,
min: min,
max: 1000000,
step: 500
});
Upvotes: 1