function init(){
		startNavigation();
		startModules();
}

function startModules(){
	moduleRoot = document.getElementById("modules");
	titleList = moduleRoot.getElementsByTagName("ul")[0];
	titles = titleList.getElementsByTagName("li");
	
	for (i=0; i<titles.length; i++) {
		node = titles[i];
		
		node.onmouseover = function() {
			
			if(this.className != "hover"){
				divs = document.getElementById("modules").getElementsByTagName("div");
				lis =  document.getElementById("modules").getElementsByTagName("li");
				for (i=0; i<divs.length; i++) {
					divs[i].className = "off";
					lis[i].className = "";
				}
				document.getElementById("mod_" + this.id).className = "on";
				this.className = "hover";
			}
		}
	}
}

function startNavigation() {
	if (document.all&&document.getElementById) {
		navRoot = document.getElementById("nav");
		
		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", "");
				}
			}
		}
	}
}

// Sets the function to run on window load
window.onload = init;
