<!--
/*
////////////////////////////////////////////////////////////////////////////
   (C) Copyright Marcus Efraimsson, 2006
       All designs and code belongs to Marcus Efraimsson!
       Contact: kontakt (at) administrationen.se
////////////////////////////////////////////////////////////////////////////
*/
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"), "");
		}
	}
}

sfHover2 = function() 
{
	var sfEls = document.getElementsByTagName("div");
	
	for (var i = 0; i < sfEls.length; i++) 
	{
		if (sfEls[i].className == "button")
		{
			var button = sfEls[i].getElementsByTagName("li");
			
			for (var n = 0; n < button.length; n++)
			{			
				button[n].onmouseover=function() 
				{
					this.className += " sfhover2";
				}
				button[n].onmouseout = function() 
				{
					this.className = this.className.replace(new RegExp(" sfhover2\\b"), "");
				}
			}
		}
		else if (sfEls[i].className == "navsub")
		{
			var button = sfEls[i].getElementsByTagName("li");
			
			for (var n = 0; n < button.length; n++)
			{			
				button[n].onmouseover=function() 
				{
					this.className += " sfhover2";
				}
				button[n].onmouseout = function() 
				{
					this.className = this.className.replace(new RegExp(" sfhover2\\b"), "");
				}
			}
		}
	}
}

//if (window.attachEvent) window.attachEvent("onload", sfHover);
if (window.attachEvent) window.attachEvent("onload", sfHover2);