var msg1; var maxlength = 58; var textlength; var count = maxlength; var space = '                                                                          '; var msg; var newscount = 0; var n_text = new Array(); var n_time = new Array(); function news10() { msg1 = n_text[newscount]; textlength = maxlength - count; if (msg1.length < textlength) textlength = msg1.length; msg = space.substring(0, count) + msg1.substring(0,textlength); document.form1.news_i.value = msg; if (count) { count--; setTimeout("news10()",20); } else { document.form1.news_i.value = msg+' '+n_time[newscount]; count = maxlength; newscount++; if (!n_text[newscount]) newscount = 0; setTimeout("news10()",2500); } }