/* The script in this file chooses which picture to display in 
*  in the upper left hand corner of the window.  
*
*  It achieves this task by using the levelA variable to deter-
*  mine which section we are in and then assigns a picture based
*  on the section.
*/

function getCornerPicture(section, rootDirectory)
{

	var picture = new Array();

	for (index=0; index <= 10; index++)
	{
		picture[index] = rootDirectory + "images/top_" + index + ".jpg";
	}
		
	document.write('<img alt="decorative montage" src="' + picture[section] + '" width=150  border=0>');
	
}


//  These three functions initialize for image rollovers


function newImage(arg)
{
	if (document.images) {
		rslt = new Image();
		rslt.src = arg;
		return rslt;
	}
}

function changeImages() 
{

	if (document.images && (preloadFlag == true)) {
		for (var i=0; i<changeImages.arguments.length; i+=2) {
			document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
		}
	}
}

	
function preloadImages() {


	if (document.images) {
		B_y_1 = newImage(rootDirectory + "images/tri_up.gif");
		B_w_1 = newImage(rootDirectory + "images/tri_down.gif");
		preloadFlag = true;
	}

}


// This function fires when the page exits

function byebye() 
{


}


//  This function takes the user to a new page based on button selection

 function getPage(pageURL)     {
   var gotoLink = pageURL;
   if (gotoLink != "0")    {
	   self.location = gotoLink;
	}
   }