// JavaScript Document
  
<!-- Telex type 2 kurt.grigg@virgin.net
 
fontfamily='Times New Roman';
cursorcolour='#330000';
fontcolour='#B61F10';
delaybetweenmessages=40;//This alters if typespeed is altered!!!
containerwidth=800;//Must be big enough to accomadate the longest message!!!
containerheight=30;
typespeed=80
fontsize=4; //1-7
msg=new Array()
msg[0]="Två vuxna cockers ges till goda och ansvarsfulla hem, ej till avel och ej till höghus";
msg[1]="";
 
//Alter nothing past here!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
ns=(document.layers);
ie=(document.all);
themessage='';
if (ns)themessage="<layer name=Tns width="+containerwidth+" height="+containerheight+">&nbsp;</layer>";
if (ie){
themessage="<div id='Tie' style='position:relative;"
+"width:"+containerwidth+";height:"+containerheight+"'></div>";
}
timer=0;
next=0;
pos=0;
a='/';
b='\\';
c='';
cursor=a;
fc1="<font face="+fontfamily+" font color="+fontcolour+" size="+fontsize+">";
fc2="<font face="+fontfamily+" font color="+cursorcolour+" size="+fontsize+">";
function Type(){
if (timer == 0) pos++;
if (msg[next].substring(pos-1,pos) == " ") pos++;
if (pos > msg[next].length) {timer++}  
if (timer > delaybetweenmessages) {next++;pos=0;timer=0;cursor=a} 
if (next == msg.length) next=0;
if (timer != 0) {cursor=c} 
if (cursor==a){cursor=b}
else if (cursor==b){cursor=a}
text=msg[next].substring(0,pos);
if (ns){
document.layers.Tns.document.open();
document.layers.Tns.document.write(fc1+''+text+'</font>'+fc2+''+cursor+'</font><br>');
document.layers.Tns.document.close();
}
if (ie){
Tie.innerHTML=fc1+''+text+'</font>'+fc2+''+cursor+'</font>';
}
setTimeout('Type()',typespeed);
}


