function animate(){ if (ban.href.indexOf(line[nextline][1])==-1) ban.href=line[nextline][1] ban.style.cursor=/void/.test(ban)? 'text': '' if (temp==line[nextline][0] & temp.length==line[nextline][0].length & nextline!=lines){ nextline++; nextchar=-1; ban.innerHTML=temp; temp=""; setTimeout("nextstep()", pause) } else if (nextline==lines & temp==line[nextline][0] & temp.length==line[nextline][0].length){ nextline=1; nextchar=-1; ban.innerHTML=temp; temp=""; setTimeout("nextstep()", pause) } else nextstep() } function nextstep(){ cursor=cursor=="_"? " " : "_" nextchar++; temp+=line[nextline][0].charAt(nextchar); ban.innerHTML=temp+cursor setTimeout("animate()", speed) }