I am trying to move a div Left a specified amount of pixels I'm using a slider that I got from here:
http://carpe.ambiprospect.com/slider/archive/v1.3/
So from the example my div looks like this:
<div class="horizontal_slider"
id="your_slider_id"
style="left: 0px;"
onmousedown="slide(event, 'your_slider_id',
'horizontal', 100, 0, 100, 101,
0, 'your_display_id');" > </div>
And If I adjust left: 0px the slider the move along its line, I've been trying to alter the left from an ajax response that looks like this:
var stateofmindint = $.ajax({ url: "function.php?state=1", async: false }).responseText;
And I try to change its Left style like this:
$("#your_slider_id").css({"left": stateofmindint +"px"});
But for some reason it stays at Left:0px, I've tried to remove the style tag in the div, but to no effect, I also tried referencing the class instead of the ID but nothing seems to be working! I am definitely getting a value everytime through ajax. Any advice would help thank you!