var TextTime = 100;    //新闻标题文字出现等待时间，越小越快

var newsi = 0;
var txti = 0;
var txttimer;

var newstitle = new Array();  //新闻标题
var fntColor = new Array();

newstitle[0]="A new exciting path to China";       
newstitle[1]="Your network – Full support";       
newstitle[2]="The Network – A complete Approach";       
newstitle[3]="Network ESL – Addressing you education needs";       
newstitle[4]="Network ESL – Understanding your requirements";       
newstitle[5]="Support Worldwide";       
newstitle[6]="Reliable, dependable and here in China";       
newstitle[7]="C&acute;mon, Join The Network";       
newstitle[8]="Connecting schools and teachers";       
newstitle[9]="A complete multi leveled approach to Education in China";       
newstitle[10]="Network ESL – Your one stop education shop in China";       
newstitle[11]="Network ESL – Unequalled services to Schools and Teachers";       
newstitle[12]="NETWORK ESL and LINK CHINA – Your Pathway to China";       
newstitle[13]="China – A challenging and rewarding experience";  


fntColor[0]="#FFB415";       
fntColor[1]="#FF6600";       
fntColor[2]="#BBBB00";       
fntColor[3]="#9BDA25";          
fntColor[4]="#A0745F";       
fntColor[5]="#FF6A59";         
fntColor[6]="#33CC00";   
fntColor[7]="#FFEE17";
fntColor[8]="#DD6F00";   
fntColor[9]="#666666"; 
fntColor[10]="#339933";   
fntColor[11]="#99FF33"; 
fntColor[12]="#3399FF";   
fntColor[13]="#B735FD"; 
fntColor[14]="#6666CC";   
fntColor[15]="#346F9E";   
fntColor[16]="#00CCFF";   
fntColor[17]="#01CDB9";   
fntColor[18]="#CCCC00";   
fntColor[19]="#CC9400";       
fntColor[20]="#FF610B";       
fntColor[21]="#00E30C"; 


function init()
{
	
	typeOut(newstitle[parseInt(newstitle.length*Math.random())],fntColor[parseInt(fntColor.length*Math.random())]);
}

function typeOut(str,clr)
{
  hwnewstr = newstitle[newsi];
  clearInterval(txttimer);
  document.getElementById("typeword").innerHTML = "<font color='"+clr+"' size='4'><B>"+str.substring(0,txti+1)+"</B></font>";
  txti++;
  txttimer = setInterval("typeOut('"+str+"','"+clr+"')",TextTime);	
}