
var topMenuTop = 40;
var topMenuLeft = 400;

var domSMenu = null;
var oldDomSMenu = null;
var t = 0;
var lDelay = 4;
var lCount = 0;
var pause = 300;

function popTopMenu(topMenuNum)
	{ if (isDHTML) 
		{ t = 2;
		  								///// Sets the previous topMenu's visibility to hidden
		  if (oldDomSMenu)
			{ oldDomSMenu.visibility = 'hidden';
			  oldDomSMenu.zIndex = '0';
			  t = 2;
			  lCount = 0;
		    }                           
		    							///// Defines the DOMs	of the topMenu objects
		  var idMenu = 'topMenuHead';
		  var domMenu = findDOM(idMenu,0);

		  var idMenuOpt = 'topMenuHead' + topMenuNum;
		  var domMenuOpt = findDOM(idMenuOpt,0);
 
		  var idSMenu = 'topMenu' + topMenuNum;
		  var domSMenu = findDOM(idSMenu,1);

										///// Defines the positions of the sub-topMenus
		  if (isID || isAll) 
		  	{ var topMenuLeft = (domMenu.offsetLeft) + (domMenuOpt.offsetLeft)+1;
			  var topMenuTop = (domMenu.offsetTop) + (domMenu.offsetHeight)+1;
			}
		  if (isLayers) 
		  	{ var topMenuLeft = document.layers[idMenu].layers[idMenuOpt].pageX - 5;
			  var topMenuTop = domMenu.pageY + domMenu.clip.height - 5;
			}

										///// Positions and shows the topMenu
		  if (oldDomSMenu != domSMenu) 
		  	{ domSMenu.left = topMenuLeft;
			  domSMenu.top = topMenuTop;
			  domSMenu.visibility = 'visible';
			  domSMenu.zIndex = '100';
			  oldDomSMenu = domSMenu;
			}

										///// Resets oldDom if it is the same as the current DOM
		  else 
		    { oldDomSMenu = null; 
		    }
		}

										////// Returns a 'null' value for non-DHTML Browsers
	  else 
	  	{ return null; 
	  	}
	}


function delayHide() 
   {
										///// Checks to see if there is a topMenu showing and whether
										///// the global variable 't' has been set to 0
      if ((oldDomSMenu) && (t == 0)) 
      	{
										///// Hides the old topMenu, resets topMenu conditions,
										///// and stops the function running
          oldDomSMenu.visibility = 'hidden';
          oldDomSMenu.zIndex = '0';
          oldDomSMenu = null;
          lCount = 0;
          return false;
    	}
										///// Interupts the function if another topMenu is opened
      if (t == 2) 
      	{ lCount = 0; return false;
      	}
										///// Repeats the function adding 1 to lCount each time until
										///// lCount is equal to lDelay and then sets 't' to 0 so that
										///// the topMenu will hide when it runs again
      if (t == 1) 
      	{ lCount = lCount + 1;
          if (lDelay <= lCount) 
          	{ t = 0; 
          	}
          if (lDelay >= lCount)
          	{ setTimeout('delayHide(' + t + ')',pause);
          	}
    	}
   }

function sendit()
	{ document.form[1].submit
	}
	
function mynewwindow(myPic)
	{ window.open(myPic,'myWindow','width=600,height=450,toolbar=0,location=0,directories=0,status=0,menubar=no,scrollbars=1,copyhistory=0,resizable=1');return false;
	}
	
function anotherwindow(myInfo)
	{ window.open(myInfo,'anotherwindow','width=600,height=450,toolbar=0,location=0,directories=0,status=0,menubar=no,scrollbars=1,copyhistory=0,resizable=1');return false;
	}
function findus()
	{ window.open('findUs.asp?mapNo=','anotherwindow','width=725,height=500,toolbar=0,location=0,directories=0,status=0,menubar=no,scrollbars=1,copyhistory=0,resizable=1');
	}