I have a div tag declared like this:
<div id="carRight" style="position:absolute; left:600px; top:170px;">
<img src="carRight.png" width="256" height="256" />
</div>
After a quick animation, I’d like to move the left position when a button is pressed. I tried a few variations of this, but it doesn’t seem to be correct:
document.getElementById('carRight').style.left=600;
document.getElementById('carRight').style.position.left=600;
What is the correct statement to use? Thanks.
Try: