function colorParentNode(n) {
	pLink = n.parentNode.getElementsByTagName('a');		//n is menu list item
	pLink[0].className = "parentBGColor";				//change css class assigned to parent link
}

function remcolorParentNode(n) {
	pLink = n.parentNode.getElementsByTagName('a');
	pLink[0].className = "";
}

function getElementsByClassName(oElm, strTagName, strClassName){
    var arrElements = (strTagName == "*" && document.all)? document.all : oElm.getElementsByTagName(strTagName);
    var arrReturnElements = new Array();
    strClassName = strClassName.replace(/\-/g, "\\-");
    var oRegExp = new RegExp("(^|\\s)" + strClassName + "(\\s|$)");
    var oElement;
    for(var i=0; i<arrElements.length; i++){
        oElement = arrElements[i];      
        if(oRegExp.test(oElement.className)){
            arrReturnElements.push(oElement);
        }   
    }
    return (arrReturnElements)
}

startList = function() {
	if (document.all && document.getElementById) {
		if (document.all("tertiaryUL") != null) {
			navRoot = document.all("tertiaryUL");
			if (navRoot.length == undefined) {
	  		for (k = 0;k < navRoot.childNodes.length; k++) {
	  			if (navRoot.childNodes[k].nodeName == "LI") {
	  				nodeLI = navRoot.childNodes[k];
			  		nodeLI.onmouseover=function() {
			  			this.className+=" over";
			    	}
			  		nodeLI.onmouseout=function() {
			  			this.className=this.className.replace(" over", "");
						}
					}
				}
			} 
			else {
				for (i=0; i<navRoot.length; i++) {
			  	node = navRoot[i];
		  		for (k = 0;k < node.childNodes.length; k++) {
		  			if (node.childNodes[k].nodeName == "LI") {
		  				nodeLI = node.childNodes[k];
				  		nodeLI.onmouseover=function() {
				  			this.className+=" over";
				    	}
				  		nodeLI.onmouseout=function() {
				  			this.className=this.className.replace(" over", "");
							}
						}
					}
				}			
			}
		}
	}
}

window.onload=startList;
