liHover = function() {
	var liEls = document.getElementById("nav").getElementsByTagName("LI");
	for (var i=0; i<liEls.length; i++) {
		liEls[i].onmouseover=function() {
			this.className+=" lihover";
		}
		liEls[i].onmouseout=function() {
			this.className=this.className.replace(new RegExp(" lihover\\b"), "");
		}
	}
}
if (window.attachEvent) window.attachEvent("onload", liHover);
