// *** THIS WILL ONLY BE USED IF THERE ARE SLIDE OUT MENUS IN THE REGIONAL MENU ***

var x1 = 170;
var x2 = 320;
var y = 180; //206
var yd = 24;
var xw = 160;
var yh = 20;

new ypSlideOutMenu("menuLocations", "right", x1, y+yd, xw, 2*yh+2);
menuLocationsLevel = new Array("menuLocations");
menuLocationsItems = new Array("Kingston","Teddington");
menuLocationsHyper = new Array("kingston","teddington");
writeMenu("menuLocations");

function writeMenu(menuName, httppath) {
document.write("<DIV ID='"+menuName+"Container'>")
document.write("<DIV ID='"+menuName+"Content'>")
document.write("<TABLE BORDER=0 CELLPADDING=0 CELLSPACING=0 class=\"menutable\"><TBODY>")

	for (i=0; i<eval(menuName+"Items").length; i++) {
		document.write("<TR CLASS=\"rollmenu\" ONMOUSEOVER=\"className='rollovermenu';")
		for (n=0; n<eval(menuName+"Level").length; n++) {
			document.write("ypSlideOutMenu.showMenu('"+eval(menuName+"Level")[n]+"');")
		}	
		if ( (eval(menuName+"Hyper")[i].substring(0,4))=="menu") {
				document.write("ypSlideOutMenu.showMenu('"+eval(menuName+"Hyper")[i]+"');")
		}
		document.write("\" ONMOUSEOUT=\"className='rollmenu';")
		for (n=0; n<eval(menuName+"Level").length; n++) {
			document.write("ypSlideOutMenu.hideMenu('"+eval(menuName+"Level")[n]+"');")
		}
		if ( (eval(menuName+"Hyper")[i].substring(0,4))=="menu") {
			document.write("ypSlideOutMenu.hideMenu('"+eval(menuName+"Hyper")[i]+"');")
 		}
			else {
				document.write("\" onClick=\"document.location = ('kingston.php?page="+eval(menuName+"Hyper")[i]+"&region="+httppath+"');")		
		}
		document.write("\"><TD CLASS=\"menucell\">")
		document.write(eval(menuName+"Items")[i])
		document.write("</TD><TD CLASS=\"chevron\">")
		if ( (eval(menuName+"Hyper")[i].substring(0,4))=="menu") { document.write(">") }
		document.write("</TD></TR>")
	}
	document.write("</TBODY></TABLE></DIV></DIV>")
} 		

