// JavaScript Document
var dM = {
	addEvent: function(elm, evType, fn, useCapture) {
			// addEvent cross-browser event handling for IE5+, NS6 and Mozilla
			// By Scott Andrew
			if (elm.addEventListener) {
			  elm.addEventListener(evType, fn, useCapture); 
			  return true;
			} else if (elm.attachEvent) {
			  var r = elm.attachEvent('on' + evType, fn);
			  return r;
			} else {
			  elm['on' + evType] = fn;
			}
	  },  
	sfHover: function() {
		var sfEls = document.getElementById("nav").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.replace(new RegExp("sfhover\\b"), "");
			}
		}
	}
}

dM.addEvent(window, 'load', dM.sfHover, false);
