//



// Initialize variables



itemz = new Array(0);



parts = new Array(0);



thisitem = new String;



//



// Initialize arrays for navigation bar teases and links



menuData = new Array();



for (i=0; i < 8; i++) {



  menuData[i] = new Array(40);



  for (j=0; j < 20; j++) {



    menuData[i][j] = new Array(2)



  }



}



//



// First, we must determine if this is a current page or a back issue. If it's a current page,



// we'll serve indexes from the /index folder; if it's a back issue, we'll serve indexes from the



// appropriate /backindex folder.



//



// Fetch the URL of this page and see if it's a backindex



thisurl = document.location.href;



locate = 0;



locate = thisurl.search(/\/backindex/);



//



// If this page is not a backindex, see if it was called by a backindex, in which case it's a



// story that should have backdated navigation



if (locate < 1) {



  if (parent != self) {



    thisurl = parent.document.referrer;



    locate = 0;



    locate = thisurl.search(/\/backindex/);



   }



}



//



// If either backindex test is positive, then form the backindex path by tearing down thisurl



if (locate > 0) {



  itemz = thisurl.split("/");



  wherebackindex = 0;



  locate = 0;



  counter = 0;



  while (counter <= (itemz.length - 1)) {



    if (wherebackindex == 0) {



      thisitem = itemz[counter];



      locate = thisitem.search(/backindex/);



      if (locate > -1) {



        wherebackindex = counter;



      }



    }



    counter = counter + 1;



  }



  thisisbackindex = 1;



  indexpath = "/backindex/" + itemz[wherebackindex + 1] + "/" + itemz[wherebackindex + 2] + "/" + itemz[wherebackindex + 3] + "/";



	newspath = "/backindex/" + itemz[wherebackindex + 1] + "/" + itemz[wherebackindex + 2] + "/" + itemz[wherebackindex + 3] + "/newsindex.htm";



	sportspath = "/backindex/" + itemz[wherebackindex + 1] + "/" + itemz[wherebackindex + 2] + "/" + itemz[wherebackindex + 3] + "/sportsindex.htm";



	homepath = "/backindex/" + itemz[wherebackindex + 1] + "/" + itemz[wherebackindex + 2] + "/" + itemz[wherebackindex + 3] + "/homepage.htm";



	featurespath = "/backindex/" + itemz[wherebackindex + 1] + "/" + itemz[wherebackindex + 2] + "/" + itemz[wherebackindex + 3] + "/featuresindex.htm";



	realpath = "/backindex/" + itemz[wherebackindex + 1] + "/" + itemz[wherebackindex + 2] + "/" + itemz[wherebackindex + 3] + "/realindex.htm";



	voicespath = "/backindex/" + itemz[wherebackindex + 1] + "/" + itemz[wherebackindex + 2] + "/" + itemz[wherebackindex + 3] + "/voicesindex.htm";



	webdaypath = "/cgi-bin/entertaintease.pl?/entertainment/thelist/qwebday.htm";



} else {



  thisisbackindex = 0;



  indexpath = "/index/";



  newspath = "/news/index.htm";



  sportspath = "/sports/index.htm";



  homepath = "/index.htm";



  featurespath = "/features/index.htm"



  realpath = "/realestate/index.htm"



  voicespath = "/voices/index.htm"



  webdaypath = "/entertainment/webday/index.htm"



}	

