function replaceChar(pStr, pChar, pReplStr) {
var strRes, i

	strRes = "";
	for (i=0; i<pStr.length; i++) {
		if (pStr.charAt(i) == pChar)
			strRes += pReplStr;
		else
			strRes += pStr.charAt(i)
	}
	return strRes
}

function popup( url ) {	
	window.open( url, 'Information','width=870,height=400,scrollbars=yes,resizable=yes' )	
}

function openWin(theURL, eWS, eHS) {
	hS = window.screen.height;
	wS = window.screen.width;
/*
	eWS = wS - 260;
	eHS = hS - 30;
	eHSNav = hS - 150;
	eHS = 350;
	alert("eWS" + eWS + "/" + "eHS" + "/" + eHS + "/" + "eHSNav" + "/" + eHSNav);
*/
	if (typeof newWin != "undefined") {
		if (!newWin.closed) {
		newWin.close();
		}
	}
	
//	alert(escape(theURL));
	theURL = replaceChar(theURL, '+', "%2B");
	newWin = window.open(theURL, "newWin", "alwaysRaised=yes,scrollbars,resizable,WIDTH=" + eWS + ",HEIGHT=" + eHS);
	newWin.moveTo(50,50);
	newWin.focus();
}
