First, realize that some people find moving content on a web page very annoying, unless it is demonstrating a concept (such as a moving how-it-works diagram). It interrupts their reading processes, so they can't easily read the stationary parts of the page.
The best way to do it I can think of is to make a .gif animation. That works on anything except lynx (it's text-only). No script is necessary.
Another way to do it is to write a script to repeatedly fill a text box with text. nibbling characters off the left end and adding them on the right end. This could be done with a simple for loop. But don't hog the processor with your script, or the user will lose cursor control.
A flash animation will work too, but is unavailable for older browsers.