Flowing
text in a text box.
var
max=0;
function textlist(){
max=textlist.arguments.length;
for(i=0; i<max; i++)
this[i]=textlist.arguments[i];}
tl = new textlist(
//Insert here the phrases that flowing,
2 or more.
// Divide the phrases with comma and use the quotes.
"This is the phrases number 1",
"Giuseppe Ciaburro",
":-)",
"My e-mail:giuseppe.ciaburro@tin.it",
"Hello",
"This is the end!!",
"");
var x=0; pos=0;
var l=tl[0].length;
function textticker(){
document.tickform.tickfield.value=tl[x].substring(0,pos)+"_";
// wait(in millisecon).
if(pos++==l) { pos=0; setTimeout("textticker()",2000);
x++;
if(x==max) x=0; l=tl[x].length; } else
// wait.
setTimeout("textticker()",50);}
Insert
in the TAG Body:
<body
onload="textticker()">
and
the following TAG in your code HTML:
<form
name="tickform">
< input type="text" name="tickfield" size="40">
</form>
|