var menuList = new Array();
var menuImage_ac = new Array();
var menuImage_mo = new Array();

function menuDef() {
	this.name;
	this.url;
	this.height;
	this.statusText;
}


function createMenuList(num, name, height, url, statusText) {
	menuList[num] = new menuDef();
	menuList[num].name = name;
	if (url != null) {
		menuList[num].url = url;
	}	
	menuList[num].height = height;
	if (statusText == null) {
		menuList[num].statusText = 'http://www.dipsea.org/' + url
	} else {	
		menuList[num].statusText = statusText;
	}	
}


createMenuList(0,'m01_home',30,'index.html');
createMenuList(1,'m02_2011',30,'2011/index.html');
createMenuList(2,'m03_prev',30,'prevresults.html');
createMenuList(3,'m04_photo',30,'gallery.html');
createMenuList(4,'m05_enter',30,'howtoenter.html');
createMenuList(5,'m06_headstart',30,'handicap.html');
createMenuList(6,'m07_history',30,'history.html');
createMenuList(7,'m08_course',30,'course.html');
createMenuList(8,'m09_volunteer',30,'volunteer.html');
createMenuList(9,'m10_foundation',30,'http://www.dipseafoundation.org/');
createMenuList(10,'m11_links',30,'links.html');
createMenuList(11,'m12_sponsors',30,'sponsors.html');
createMenuList(12,'m13_contact',30,'contact.php');

function imgMOon(imgName) {
	document[imgName].src = eval(imgName+"_mo.src");
}

function imgMOoff(imgName) {
	document[imgName].src = eval(imgName+"_ac.src");
}

function imgNumMOon(imgNum) {
	document[menuList[imgNum].name].src = menuImage_mo[imgNum].src;
}

function imgNumMOoff(imgNum) {
	document[menuList[imgNum].name].src = menuImage_ac[imgNum].src;
}


document.write('<TABLE width=100% height=100% cellpadding="0" cellspacing="0" border="0">');
	document.write('<TR>');
		document.write('<TD width=788 bgcolor="#DCDCFF" colspan=3 height=102><IMG src="' + path + 'images/header.jpg" alt="The Dipsea Race: Old runners never die; they just reach the 672nd step. -Jack Kirk" border="0"></TD>');
		document.write('<TD bgcolor="#DCDCFF"><img src="' + path + 'images/pixel.gif" width="1" height="1" alt="" border="0"></TD>');
	document.write('</TR>');
	document.write('<TR>');
		document.write('<TD bgcolor="#5461A2" width=140 valign="top">');
		document.write('<img src="/images/m00_top.jpg" width="140" height="4" alt="" border="0">');



for (var i=0; i<menuList.length; i++) {
	if (menuList[i].url == null) {
		document.write('<img src="' + path + 'images/' + menuList[i].name + '.jpg" border="0" width="140" height="' + menuList[i].height + '">');
	} else if (selected == i) {
		document.write('<img src="' + path + 'images/' + menuList[i].name + '_se.jpg" border="0" width="140" height="' + menuList[i].height + '">');
	} else {
		menuImage_ac[i] = new Image();
		menuImage_ac[i].src = path + "images/" + menuList[i].name + "_ac.jpg";
		menuImage_mo[i] = new Image();
		menuImage_mo[i].src = path + "images/" + menuList[i].name + "_mo.jpg";
		document.write('<A target="_top" href="' + path +menuList[i].url+'" onMouseOver="javascript:imgNumMOon(' + i + ')" onmouseout="javascript:imgNumMOoff(' + i + ')"><img src="' + path + 'images/' + menuList[i].name + '_ac.jpg" width="140" height="' + menuList[i].height + '" border="0" name="' + menuList[i].name + '"></A>');
	}
}

document.write('<img src="' + path + 'images/m14_bottom.jpg" width="140" height="206" alt="" border="0">');
			
						
document.write('<TD bgcolor="#FFFFFF" width=10><img src="images/pixel.gif" width="1" height="1" alt="" border="0"></TD>');
document.write('<TD bgcolor="#FFFFFF" width=653 valign="top"><BR>');
