<!--



var menuArray = new Array();
for (i=0; i<3; i++) {
	menuArray[i]= new Array()
}

menuArray[0][0]="Company";
menuArray[0][1]="down";
menuArray[1][0]="Expertise";
menuArray[1][1]="down";
menuArray[2][0]="Support";
menuArray[2][1]="down";

var subNavArray = new Array("news",
							"location0",
							"people",
							"contact",
							"services0",
							"clients",
							"case",
							"account",
							"help",
							"virus"
							);

//code to select and display the active menu for a given page
//the variable "activeMenu" is set in the head of each page linking to this script

if (activeMenu != "null") {
	for (i=0; i<menuArray.length; i++) {
		if (activeMenu == menuArray[i][0]){
			var theLayer = "menu" + menuArray[i][0];
			if (ie) {
				//alert(theLayer);
				document.all[theLayer].style.top = 25;
			}	
			if (ns) {
				document.getElementById(theLayer).style.top = 25;
			}
		}
	}
}


//scroll menu up
function menuOn(whichMenu, position) {
	//make sure menu isn't already up
	
	if ((menuArray[whichMenu][0] != activeMenu) && (menuArray[whichMenu][1] == "down")) {
		var theLayer = "menu" + menuArray[whichMenu][0];
		tempMenu = whichMenu;
		tempPos = position-5;
		//move menu up
		if ((tempPos > 20) && (menuArray[whichMenu][1] != "up")) {
			if (ie) {
				document.all[theLayer].style.top = tempPos;
			}	
			if (ns) {
				document.getElementById(theLayer).style.top = tempPos;
			}
			setTimeout("menuOn(tempMenu, tempPos)",1);
		} else {
			menuArray[whichMenu][1]="up";	
		}
	}
}

function allMenusDown(whichMenu) {
	//alert(whichMenu);
	for (i=0; i<menuArray.length; i++) {
		
		// if the calling mouse event originates from any menu
		// and if that menu is already in the up position - break
		if (whichMenu != -1) {
			var calleeMenu = "menu"+menuArray[whichMenu][0];
			if (ie) {
				 calleeMenuPos = document.all[calleeMenu].style.top;
			}
			if (ns) {
				var calleeMenuPos = document.getElementById(calleeMenu).style.top;
			}
			calleeMenuPos = parseInt(calleeMenuPos.substr(0,2));
			
			if (calleeMenuPos == 25)  {
				//alert('break here');
				break;
				
			}
		}
	
		if (menuArray[i][0] != activeMenu) {
			menuArray[i][1]="down"
			downPos = 82;
			var theLayer = "menu" + menuArray[i][0];
			//alert(theLayer + "  " + downPos);
			if (ie) {
				var calleeMenuPos = document.all[theLayer].style.top;
				
				calleeMenuPos = parseInt(calleeMenuPos.substr(0,2));
				//alert(calleeMenuPos);
				if (calleeMenuPos == 25) {
					//alert('inside'+calleeMenuPos)
					document.all[theLayer].style.top = downPos;
				}
			}	
			if (ns) {
				var calleeMenuPos = document.getElementById(theLayer).style.top;
				calleeMenuPos = parseInt(calleeMenuPos.substr(0,2));
				//alert(calleeMenuPos);
				if (calleeMenuPos == 25) {
					document.getElementById(theLayer).style.top = downPos;
				}
			}
		}
	}
}
	

// swap out the appropriate subnav menu onload depending on what "activeSubNav"is set to on each page
function initSubnav() {
	for (i=0; i<subNavArray.length; i++) {//alert(subNavArray[i] + "  |  " + activeSubNav);
		if (subNavArray[i] == activeSubNav) {
			img=subNavArray[i];
			//alert("images/subnav_" + subNavArray[i] + "_on.gif");
			//document[img].src="images/subnav_people_on.gif";
			document[img].src="images/subnav_" + subNavArray[i] + "_on.gif";
		}
	}
}
	
	
function swapImg(whichNav,state) {
	var tempSubNav = whichNav;
	//alert(whichNav)
	//document['services0'].src="images/subnav_" + whichNav + "_" + state + ".gif";
	if (whichNav != activeSubNav) {
		var tempSubNav = whichNav;
		//alert("field name= " + tempSubNav + "   images/subnav_" + whichNav + "_" + state + ".gif")
		//document['services0'].src="images/subnav_" + whichNav + "_" + state + ".gif";
		document[tempSubNav].src="images/subnav_" + whichNav + "_" + state + ".gif";
	}
}
	

//-->