AutoScroll div content both ways
<p>I want to make a div autoscroll it's content. The content height is variable. Here is what I managed to work out, but if I set the height to .childElement.outerHeight or height, it will only scroll 78px, I don't know why.</p>

<pre><code> var element = jQuery('#content');
            setInterval(scrollDown(element), 1000)

        function scrollDown(element) {
            var childElement = element.children();
            scrollAmount = childElement.outerHeight();
            element.animate({ scrollTop: 1000 }, 3000, null, scrollUp(childElement));
        }
        function scrollUp(element) {
            element.animate({ scrollTop: 0 }, 500);
        }

        });
</code></pre>

<p>Any help is highly appreciated.</p>

<p>Thanks,
Sebastian</p>
