function URLEncode(sVal)
{
	// Use regular expressions to replace problem characters
	var regExpr
	// Replace "&"
	regExpr = /&/g
	sVal = sVal.replace(regExpr, "%26")
	// Replace "#"
	//regExpr = /#/g
	//sVal = sVal.replace(regExpr, "%23")
	// Replace " "
	regExpr = / /g
	sVal = sVal.replace(regExpr, "%20")
	return sVal;
}
function ResizeBrowserWindow(lWidth, lHeight)
{
	window.resizeTo(lWidth, lHeight);
}
function GoHREF(sPage)
{
	//this function has to be here to resolve some netscape 4.01 problems
	this.location="/" + sPage;
}
function PopUpWin(sPage, lWidth, lHeight, sWinName)
{
	if(!lWidth)
		lWidth = 680;
	if(!lHeight)
		lHeight = 400;
	mywin = open(sPage,sWinName,'width=' + lWidth + ',height=' + lHeight + ',scrollbars=yes,toolbar=no,location=no,status=no,resizable=yes,menubar=no');
}
function checkBrowser()
{
	//if(window.navigator.appVersion.substr(0, 1) < 4)
	//	top.location = "browser.asp";
}

function GetCookie(sName)
{
	var aCookie = document.cookie.split("; "); 
	for (var i=0; i < aCookie.length; i++) 
	{
		var aCrumb = aCookie[i].split("=");
		if (sName == aCrumb[0]) 
			return unescape(aCrumb[1]);
	}
}