Possible Duplicate:
Implementing circular scroller in jquery
I want to create vertical scroller, which will work exactly like marquee. But I want it to be continuous, like when we use marquee the whole content comes back only after it completely goes up, but I want it to be continuous.
this is what I have... http://jsfiddle.net/JWfaf/1/
I want only in one direction and keep on scrolling. I hope I have cleared what I want to achieve
HTML
<div class="con">
<ul>
<li></li>
<li></li>
<li></li>
<li></li>
</ul>
</div>
JavaScript
function animatethis(targetElement, speed) {
$(targetElement).animate({ marginTop: "+=250px"},
{
duration: speed,
complete: function ()
{
targetElement.animate({ marginTop: "-=250px" },
{
duration: speed,
complete: function ()
{
animatethis(targetElement, speed);
}
});
}
});
};
animatethis($('.con ul li:first-child'), 10000);