    sfHover = function() {
try {
    var sfEls = document.getElementById("topmenu").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"), "");
      }
    }
} catch(e) { }
  }
  if (window.attachEvent) 
  {
     window.attachEvent("onload", sfHover); 
  }
  
  
var leavingmessage = 'You are about to leave the Bayer Australia and New Zealand website. \nThe site you are going to may not comply with the Australian / New Zealand regulatory environment. \nRegulatory restrictions and medical practices may vary from one country to another and, as a result, the information given in the site to which you are going may not be relevant to the country in which you are living. \nAny information provided should be discussed with your health care professional and does not replace their advice. \n\nDo you wish to proceed?';
	
function switchSite(dropDown) {
	if (dropDown != null) {
		var href = dropDown.value;
		var external = (href.indexOf("http")>-1)?true:false;
		if (href == '') {return;}

		if (external) {
			if(confirm(leavingmessage))
				window.open(dropDown.value,"newwindow","toolbar=yes,location=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width=800,height=600");
		} else {
			document.location.href = href;
		}
	}
}

$().ready(function() {
	$("a").click(function(){
		var external = ($(this).attr('href').indexOf("http")>-1)?true:false;
		if(external)
			return confirm(leavingmessage);
		else
			return true;
	});
});


