I have this code:
HTML:
<div class="rotatingbg">
<div id="bg1"></div>
</div>
jQuery:
function animatebg() {
$('#bg1').animate({left:'-4500px'}, 25000, 'linear', animatebg);
}
However, the animation only runs one time and doesn't loop infinitely even if I called the function within the function.
What's missing or incorrect?