// Function to pop up a window
// Arguments:   page = Page to open (e.g. "./maleavepop.asp")

function blowCookies()
{
  var theCookies = document.cookie.split(";");
  var cookDic = new Array();
  for (i=0; i < theCookies.length; i++)
  {
   theCookie = theCookies[i].split("=");
   key = (theCookie[0].charAt(0) == " ") ? theCookie[0].substr(1).toLowerCase() : theCookie[0].toLowerCase();
   cookDic[key] = theCookie[1];
  }
 return cookDic;
}

function leavepop(page) {
	if (blnExternalOK == false) {
	    var windowprops = "location=no,scrollbars=yes,menubars=no,toolbars=no,resizable=no,left=0,top=0,width=10,height=10";
	    var cookiedic = blowCookies();

		// showPopUp is set in inc\head.asp
	    if(typeof showPopUp != "undefined"){
			if (showPopUp){
				popup = window.open(page,"popup",windowprops);
			}
	    }
	}
}

var leftOK;
var blnExternalOK;
function resetPopVars() {
	// Set blnExternal to true using onclick="blnExternalOK = true;" for any external
	// buttons/links when you don't want the popup window to display
	blnExternalOK = false;
    leftOK = true;
}
//-->