[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Status Banner



At 02:13 PM 2/16/96 +0000, you wrote:
>I am a bit of a novice (less than 24 hours) at JavaScript but I am curious 
>why scripts to write text to the Status bar were many lines long when a 
>function such as my banner() below will do the trick in 3 lines.
>
>Am I missing something obvious that means I will be asking for trouble later?
>
>
><SCRIPT LANGUAGE="JavaScript">
><!-- Beginning of JavaScript Applet -------------------
>
>var Text = "...Visit the Toc H Home Pages @
http://www.phon.ucl.ac.uk/home/dave/TOC_H/index.html.....";;
>var Speed=100
>
>
>function banner() {
>var TimerId
>	window.status=Text;
>        Text = Text.substring (1, Text.length) + Text.substring (0, 1)
>	TimerId = setTimeout("banner()", Speed);

This is essentially what I have with my frame banner (I have other stuff to
stop and start the scroll, change the color and font size, etc, but the text
display uses this same approach), and I don't believe it's asking for trouble.

-- Gordon