// create image array
var myImages = new Array();
myImages[0] = new Image(25,50);
myImages[1] = new Image(25,50);
myImages[2] = new Image(25,50);
myImages[3] = new Image(25,50);
myImages[4] = new Image(25,50);
myImages[5] = new Image(25,50);
myImages[6] = new Image(25,50);
myImages[7] = new Image(25,50);
myImages[8] = new Image(25,50);
myImages[9] = new Image(25,50);
myImages[10] = new Image(25,50);
myImages[11] = new Image(25,50);
myImages[12] = new Image(25,50);
myImages[13] = new Image(25,50);
myImages[14] = new Image(25,50);
myImages[15] = new Image(25,50);
myImages[16] = new Image(25,50);
myImages[17] = new Image(25,50);
myImages[18] = new Image(25,50);
myImages[19] = new Image(25,50);

// preload images
myImages[0].src = "graphics/top-news_on.gif";
myImages[1].src = "graphics/top-material_on.gif";
myImages[2].src = "graphics/top-article_on.gif'";
myImages[3].src = "graphics/top-competition_on.gif";
myImages[4].src = "graphics/top-misc_on.gif";
myImages[5].src = "graphics/header.gif";
myImages[6].src = "graphics/top-news.gif"
myImages[7].src = "graphics/top-material.gif"
myImages[8].src = "graphics/top-article.gif"
myImages[9].src = "graphics/top-competition.gif"
myImages[10].src = "graphics/top-misc.gif"
myImages[11].src = "graphics/logo_news.gif"
myImages[12].src = "graphics/blank.gif"
myImages[13].src = "graphics/bacgr_line.gif"
myImages[14].src = "graphics/title_news.gif"
myImages[15].src = "graphics/tbl_top.gif"
myImages[16].src = "graphics/tbl_back_left.gif"
myImages[17].src = "graphics/tbl_back_rght.gif"
myImages[18].src = "graphics/tbl_bottom.gif"
myImages[19].src = "graphics/jus_lower.gif"

// creat a global timer variable w/ half sec loop
var myTimer = setTimeout("loadNewPage();",500);

function loadNewPage(){
 var flag = new Boolean(false);
 for(var i=0; i < myImages.length; i++){
  if(myImages[i].readyState=="complete"){
   flag=true;
  }
  else{
   flag=false;
  }
 }
 if(flag==false){
  myTimer = setTimeout("loadNewPage();",500);
  return;
 } 
}