function checkBrowserName(name)
{  
   var agent = navigator.userAgent.toLowerCase();  
   if (agent.indexOf(name.toLowerCase())>-1) {  
      return true;  
   }  
   return false;  
} 


sfHover = function()
    {
       var lang = document.getElement('html').lang;
	   
       var sfEls = document.getElementById("mainMenu").getElementsByTagName("LI");

       for (var i=0; i<sfEls.length; i++)
       {
		  
          sfEls[i].onmouseover=function()
          {
             this.className+=" sfhover";
			 if(checkBrowserName('MSIE 7.0'))
			 {
				 if(this.className == "parent item2 sfhover" || this.className == "parent active item2 sfhover")
				 {
					if(lang == "de-de")
						this.style.width = 165;
					else if(lang == "en-gb")
						this.style.width = 172;
					else if (lang == "sl-si")
						this.style.width = 160;
					else //if (lang == "hr-hr")
						this.style.width = 167;
				 }
				 else if(this.className == "parent item4 sfhover" || this.className == "parent active item4 sfhover")
				 {
					if(lang == "de-de")
						this.style.width = 74;
					else if(lang == "en-gb")
						this.style.width = 81;
					else if(lang == "sl-si")
						this.style.width = 51;
					else //if(lang == "hr-hr")
						this.style.width = 56;
				 }
			 }
		  }

          sfEls[i].onmouseout=function()
          {
             this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
          }
       }
    }
    if (window.attachEvent) window.attachEvent("onload", sfHover);
	

