// JavaScript Document

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function ShowEmail(user, domain, anchor) {
	var OutText = '';
	OutText += '<a href="mailto:' + user + '@' + domain + '">';
	if (anchor != '') OutText += anchor;
	else OutText += user + '@' + domain;
	OutText  += '</a>';
	document.write(OutText);
}

function clickButton(e, buttonid){ 
      var bt = document.getElementById(buttonid); 
      if (typeof bt == 'object'){ 
            if(navigator.appName.indexOf("Netscape")>(-1)){ 
                  if (e.keyCode == 13){ 
                        bt.click(); 
                        return false; 
                  } 
            } 
            if (navigator.appName.indexOf("Microsoft Internet Explorer")>(-1)){ 
                  if (event.keyCode == 13){ 
                        bt.click(); 
                        return false; 
                  } 
            } 
      } 
} 

function popup_open(url, width, height)
{
	var param = "width="+width+", height="+height+", left=50, top=50";
	window.open(url,"", param);
}

function externalLinks() { 
	if (!document.getElementsByTagName) return; 
 	var anchors = document.getElementsByTagName("a"); 
 	for (var i=0; i<anchors.length; i++) { 
   		var anchor = anchors[i]; 
   		if (anchor.getAttribute("href") && anchor.getAttribute("rel") == "external") 
     			anchor.target = "_blank"; 
	 } 
} 
window.onload = externalLinks;



function doHidePopUp() {
	popdiv=document.getElementById("popup")
	popdiv.style.visibility="hidden"
	}
	
function doShowPopUp(){
	popdiv=document.getElementById("popup")
	popdiv.style.left="50%"
	popdiv.style.marginLeft="-223px"
	if ((is_ie5up) && (is_mac)){ //fix for ie-mac does not accept popdiv.style.top="50%"
		popdiv.style.top="0px"
		popdiv.style.marginTop="0px"
	}else{
		popdiv.style.top="50%"
		popdiv.style.marginTop="-132px"
	}
	popdiv.style.visibility="visible"
}



function popupTimer() { 
	var t=setTimeout("document.getElementById('popup').style.display = 'block';",6000);
} 
//window.onload = popupTimer;

