<script>
$(document).ready(function() {
$('#scrollingtext').bind('marquee', function() {
var ob = $(this);
var tw = ob.width();
var ww = ob.parent().width();
ob.css({ right: -tw });
ob.animate({ right: ww }, 20000, 'linear', function() {
ob.trigger('marquee');
});
}).trigger('marquee');
});
</script>
<div id="scrollingtext"></div>
i am doing foreach with this scrollingtext div so second time it does not scroll bec. of same id.. i tried some $(this).unbind(); thing but could not solve it.. i need to scroll every id=scrollingtext inside foreach any help may save my hours..
HTML only allows a single ID on the same page. Use a class instead. Problem solved.