/*
Tabs Menu (mouseover)- By Dynamic Drive
For full source code and more DHTML scripts, visit http://www.dynamicdrive.com
This credit MUST stay intact for use
*/

var	menuobj,
	tmpFunc = window.onload;

window.onload = function() {

	if (tmpFunc) tmpFunc();
	menuobj = document.getElementById ? document.getElementById("describe") : document.all ? document.all.describe : document.layers ? document.ddm1.document.ddm2 : "";
};

var submenu=new Array()
//Set submenu contents. Expand as needed. For each content, make sure everything exists on ONE LINE. Otherwise, there will be JS errors.
submenu[0]=''
submenu[1]='__________________<a href="aboutddm.html" class="subheader">Our Project</a> | <a href="roi.html" class="subheader">Our Future</a> | <a href="ddmdocuments.html" class="subheader">Documents</a> | '
submenu[2]='__________________________________<a href="vision.html" class="subheader">Our Vision</a> | <a href="plans.html" class="subheader">Site Plans</a> | <a href="exhibits.html" class="subheader">Exhibits</a> | '
submenu[3]='-__________________________________________________<a href="volunteer.html" class="subheader">Volunteer</a> | <a href="https://app.etapestry.com/hosted/DiscoveryMuseumofDurango_1/OnlineDonation.html" class="subheader">Donate</a> | <a href="giftways.html" class="subheader">Ways to Give</a> | '
submenu[4]='__________________________________________________________<a href="pr.html" class="subheader">Press Releases</a> | <a href="WebCalendar/month.php" class="subheader" target="_blank">Upcoming Events</a> | <a href="promotions.html" class="subheader">Promotions</a> | '
submenu[5]='-____________________________________________________________________________<a href="organization.html" class="subheader">Organization</a> | <a href="advisors.html" class="subheader">Advisors</a> | '

//Set delay before submenu disappears after mouse moves out of it (in milliseconds)
var delay_hide=900


/////No need to edit beyond here
function showit(which) {

	clear_delayhide();
	thecontent = (which==-1) ? "" : submenu[which];
	if (document.getElementById || document.all) {
		menuobj.innerHTML = thecontent;
	} else if (document.layers) {
		menuobj.document.write(thecontent);
		menuobj.document.close();
	}
}

function resetit(e) {

	if (document.all&&!menuobj.contains(e.toElement))
		delayhide=setTimeout("showit(-1)",delay_hide);
	else if (document.getElementById&&e.currentTarget!= e.relatedTarget&& !contains_ns6(e.currentTarget, e.relatedTarget))
		delayhide=setTimeout("showit(-1)",delay_hide);
}

function clear_delayhide() {

	if (window.delayhide)
		clearTimeout(delayhide);
}

function contains_ns6(a, b) {

	while (b.parentNode) {

		if ((b = b.parentNode) == a) return true;
	}
	return false;
}
