if (typeof chain_onload == 'undefined') {
	function chain_onload(f) {
		var p = window.onload;
		window.onload = function() { if (p) p(); f(); }
	}
}

function startList() {
	if (document.all && document.getElementById) {
		navRoot = document.getElementById("nav");
		if (!navRoot) { return; }
		for (i=0; i<navRoot.childNodes.length; i++) {
			node = navRoot.childNodes[i];
			if (node.nodeName=="LI") {
				node.onmouseover=function() {
					this.className+=" over";
				}
				node.onmouseout=function() {
					this.className=this.className.replace(" over", "");
				}
			}
		}
	}
}

function startList() {
	if (document.all && document.getElementById) {
		navRoot = document.getElementById("dlist");
		if (!navRoot) { return; }
		for (i=0; i<navRoot.childNodes.length; i++) {
			node = navRoot.childNodes[i];
			if (node.nodeName=="LI") {
				node.onmouseover=function() {
					this.className+=" over";
				}
				node.onmouseout=function() {
					this.className=this.className.replace(" over", "");
				}
			}
		}
	}
}

function toggle(id){
	ul = "ul_" + id;
	img = "img_" + id;
	ulElement = document.getElementById(ul);
	imgElement = document.getElementById(img);
	if (ulElement){
		if (ulElement.className == 'closed'){
			ulElement.className = "open";
			imgElement.src = "http://www.chancellor.mnscu.edu/images/opened.gif";
		}else{
			ulElement.className = "closed";
			imgElement.src = "http://www.chancellor.mnscu.edu/images/closed.gif";
		}
	}
}

chain_onload( startList );