<!--
// Initialize Popup script values
// Ver 1.07
// Last updated: 2004-04-16

var shown='';
var defWinCaption='Popup';
var defWaitMessage='Loading, please wait...';
var sBgColor=' bgcolor="#F5F5DC"';
var sFontStyle=' face="arial" size=4 color="#B98701"';

var windowwidth,windowheight,windowleft,windowtop;
var _toolbar,_location,_directories,_directories,_status,_scrollbars,_resizable,_copyhistory,_menubar;

// Param functions        
function setPopUpSize(w,h,l,t) {
	var a = setPopUpSize.arguments;
	if (w) windowwidth=w;
	if (h) windowheight=h;
	if (a.length>=3) {windowleft=l} else if (window.screen) windowleft=(screen.width-windowwidth)/2;
	if (a.length>=4) {windowtop=t;} else if (window.screen) windowtop=(screen.height-windowheight)/2;
}

function setPopUpParamDef() {
	setPopUpSize(500,400);
	_toolbar='no';_location='no';_directories='no';_directories='no';
	_status='yes';_scrollbars='yes';_resizable='yes';_copyhistory='no';_menubar='no'
}

// Popup functions
function PopUpEx(url,wName) {
	//KillPopup();
	if (!wName || wName.length==0) wName = defWinCaption;
	shown=window.open(url, wName, 'left='+windowleft+',top='+windowtop+
		',toolbar='+_toolbar+',location='+_location+',directories='+_directories+
		',menubar='+_menubar+',status='+_status+',scrollbars='+_scrollbars+',resizable='+_resizable+
		',copyhistory='+_copyhistory+',width='+windowwidth+',height='+windowheight);
	shown.focus();
	return false;
}

function PopUp(url) { return PopUpEx(url, defWinCaption); }

function PopUpExx(url,wName,sMessage) { 
	KillPopup();
	PopUpEx(url, wName); 
	if (sMessage!='') sMessage = defWaitMessage;
	shown.document.write('<body'+sBgColor+'><title>'+sMessage+'</title>')
	shown.document.write('<center><font'+sFontStyle+'>'+sMessage+'</font></center></body>');
}

function KillPopup() { if (!(shown=='' || shown.closed)) {shown.close();} }

function ClosePopup() {
	if (window.opener) {
		window.opener.focus();
		window.close();
	}
}

// Initialization
window.onunload=KillPopup;
setPopUpParamDef();

// popup end 
//-->