
function sfHover() {
	var sfEls = document.getElementById("mainmenu").getElementsByTagName("LI");
	for (var i=0; i<sfEls.length; i++) {
		sfEls[i].onmouseover=function() {
			this.className += " sfHover";
		}
		sfEls[i].onmouseout=function() {
			this.className=this.className.substring(0, this.className.indexOf(' '));
		}
	}
}
function activeTabs() {
	var tabs=document.getElementById("mainmenu").getElementsByTagName("UL");
	for (var j=0; j<tabs.length; j++) {
			tabs[j].onmouseover=function() {
				this.parentNode.firstChild.className += ' activeTab';
			}
			tabs[j].onmouseout=function() {
				this.parentNode.firstChild.className=this.parentNode.firstChild.className.replace(new RegExp(" activeTab\\b"), "");
			}
	}
}

function showActive(elem) {
	elem.parentNode.parentNode.parentNode.firstChild.className += ' onState';
}
function hideActive(elem) {
	elem.parentNode.parentNode.parentNode.firstChild.className = elem.parentNode.parentNode.parentNode.firstChild.className.replace(new RegExp(" onState\\b"), "");
}
