<!--

//WORK!

var imagePath = "images/";
//if (admin) {imagePath = "../";}

	var offButton = new Array();
offButton[0] = new Image();
offButton[1] = new Image();
offButton[2] = new Image();
offButton[3] = new Image();
offButton[4] = new Image();
offButton[5] = new Image();
offButton[6] = new Image();
offButton[7] = new Image();
offButton[8] = new Image();



offButton[0].src= "images/menu-homepage-off.gif";
offButton[1].src= "images/menu-about-off.gif";
offButton[2].src= "images/menu-action-off.gif";
offButton[3].src= "images/menu-regen-off.gif";
offButton[4].src= "images/menu-event-off.gif";
offButton[5].src= "images/menu-gallery-off.gif";
offButton[6].src= "images/menu-membership-off.gif";
offButton[7].src= "images/menu-contacts-off.gif";
offButton[8].src= "images/menu-calendar-off.gif";



var onButton = new Array();
onButton[0] = new Image();
onButton[1] = new Image();
onButton[2] = new Image();
onButton[3] = new Image();
onButton[4] = new Image();
onButton[5] = new Image();
onButton[6] = new Image();
onButton[7] = new Image();
onButton[8] = new Image();


onButton[0].src= "images/menu-homepage-on.gif";
onButton[1].src= "images/menu-about-on.gif";
onButton[2].src= "images/menu-action-on.gif";
onButton[3].src= "images/menu-regen-on.gif";
onButton[4].src= "images/menu-event-on.gif";
onButton[5].src= "images/menu-gallery-on.gif";
onButton[6].src= "images/menu-membership-on.gif";
onButton[7].src= "images/menu-contacts-on.gif";
onButton[8].src= "images/menu-calendar-on.gif";






function button_on(place,imageno)


    {
	
		
        // for each button set the image to show for a mouse over

        document.images[place+imageno].src= onButton[imageno].src;

}
function button_off(place,imageno)

   {
       
	

        // for each button set the image to show when mouse is moved away

      document.images[place+imageno].src= offButton[imageno].src;
}


var menus = new Array();

menus[0] = "none";
menus[1] = "menu1layer";
menus[2] = "none";
menus[3] = "none";
menus[4] = "none";
menus[5] = "menu4layer";
menus[6] = "menu5layer";
menus[7] = "none";
menus[8] = "switchOff";

function switchoff(){

 	if (isCSS){
 
 		for (i=0; i<menus.length; i++){
	
			if (menus[i] != "none") {
			theObj = getObject(menus[i]);
			theObj.display = "none";
			}
			
		}
	}
 
 }
 
 
 
function switchon(theMenu){
 //alert (theMenu)
 	var browserVer=navigator.appVersion;
	var browserAgent=navigator.userAgent;
 
 	var notMacIE = true;
 	if (browserVer.indexOf("MSIE 5")>-1 && browserAgent.indexOf("Mac")>-1){
		notMacIE = false; 
		//alert("no menus");
	}
 
 	if (isCSS && notMacIE){
	//alert (notMacIE);
 	//alert (isCSS);
 		for (i=0; i<(menus.length-1); i++){
			//alert (menus[i]);
			if (menus[i] == theMenu) {
			theObj = getObject(menus[i]);
			//alert (theObj);
			theObj.display = "block";
			}else if (menus[i] != theMenu && menus[i] != "none"){
			theObj = getObject(menus[i]);
			theObj.display = "none";
			}
			
		}
		
		switchMeOff= getObject('switchOff');
		switchMeOff.display = "block";
		
	}

}

function shiftTo(obj, x, y) {
    var theObj = getObject(obj);
    if (theObj) {
        if (isCSS) {
            // equalize incorrect numeric value type
            var units = (typeof theObj.left == "string") ? "px" : 0 
            theObj.left = x + units;
            theObj.top = y + units;
        } else if (isNN4) {
            theObj.moveTo(x,y)
        }
    }
}

function positionNav(){
				
				var screenCentre = parseInt(alertSize()/2);
				var menuYPos = 145;
				var wholeMenuWidth = 779;
				var startPos = screenCentre - (parseInt(wholeMenuWidth/2));
				if (startPos < 0){startPos = 0;}
				//alert("browser window="+alertSize()+" screenCentre="+screenCentre+" startPos="+startPos);
				shiftTo("menu1layer", (startPos+141), menuYPos);
				//shiftTo("menu2layer", (startPos+304), menuYPos);
				//shiftTo("menu3layer", (startPos+384), menuYPos);
				shiftTo("menu4layer", (startPos+522), menuYPos);
				shiftTo("menu5layer", (startPos+613), menuYPos);
				shiftTo("switchOff", (parseInt(screenCentre-389.5)), 0);
}




//-->



















//-->