
// Open a new Browser window
function OpenNewBrowser(strFilePath, intWidth, intHeight, bShowMenu)
{
	var strYesNoMenuBar = "no";
	if(bShowMenu) {
		strYesNoMenuBar = "yes";
	}

	if (document.getElementById)
		var xMax = screen.width, yMax = screen.height;
	else
		if (document.layers)
			var xMax = window.outerWidth, yMax = window.outerHeight;
		else
			var xMax = 640, yMax=480;

	var xOffset = (xMax - intWidth)/2, yOffset = (yMax - intHeight)/2;

	apwindow = open("","","menubar=" + strYesNoMenuBar + ",resizable=yes,scrollbars=yes,copyhistory=yes,width=" + intWidth + ",height=" + intHeight + ',screenX='+xOffset+',screenY='+yOffset+',top='+yOffset+',left='+xOffset+'');
	apwindow.location.href = strFilePath;
	return apwindow;
}

function BodyOnLoad(elem)
{
	document.getElementById('RightPanel').style.height = (document.getElementById('Table_01').offsetHeight - 178) - document.getElementById('Login-Cart').offsetHeight;
}

function OnLoginButton(strUName, strPass)
{
	if(strUName == "" || strPass == "")
	{
		alert("Email and Password fields must be filled in correctly.");
	}
	else
	{
		location.href = 'https://www.prosonic-studios.com/Secure/Login.aspx?strUName=' + strUName + '&strPass=' + strPass;
	}
}

function OnForgotPass(strUName)
{
	if(strUName == "")
	{
		alert("Please enter your e-mail address into the login form then press forgot password again.");
	}
	else
	{
		location.href = 'http://www.prosonic-studios.com/fgtPass.aspx?strUName=' + strUName;
	}
}

function OnDownloadClick(elem)
{
	elem.innerHTML = 'CLICKED';
}
