function loadPage(url, target)
{
	//Configure window measuremenst for 90% of available screen and centered.
	var windowHeight = Math.round(screen.availHeight) - 31;
	var windowWidth = Math.round(screen.availWidth) - 11;
	var windowTop = 0; //Math.round((screen.availHeight - windowHeight) / 2);
	var windowLeft = 0; //Math.round((screen.availWidth - windowWidth) / 2);

	//Open the Pre-Registration Page in a new fitted window.
	open(url, target, "top=" + windowTop + ", left=" + windowLeft + ", location=0, toolbar=0, directories=0, status=0, menubar=0, scrollbars=1, resizable=1, fullscreen=0, width=" + windowWidth + ", height=" + windowHeight + ", dependant=yes");
}

function buttonMouseOver(element, overImg)
{
	element.src=overImg;
}

function buttonMouseOut(element, outImg)
{
	element.src=outImg;
}

function validatePostCode(postCodeForm)
{
	if (postCodeForm.state.value == "none")
	{
		alert("Please specify a State.");
		return false;
	}
	if (postCodeForm.postcode.value == "")
	{
		alert("Please enter a valid post code.");
		return false;
	}
	else
	{
		var code = parseInt(postCodeForm.postcode.value);
		if (code < 0 || code > 9999)
		{
			alert("Please enter a valid post code.");
			return false;
		}
	}
	return true;
}
function applyError()
{
	var url = "applyError.asp";
	var target= "applyError";
	var windowHeight = 200;
	var windowWidth = 300;
	var windowTop = Math.round((screen.availHeight - windowHeight) / 2);
	var windowLeft = Math.round((screen.availWidth - windowWidth) / 2);

	//Open the Pre-Registration Page in a new fitted window.
	window.open(url, target, "top=" + windowTop + ", left=" + windowLeft + ", location=0, toolbar=0, directories=0, status=0, menubar=0, scrollbars=0, resizable=0, fullscreen=0, width=" + windowWidth + ", height=" + windowHeight + ", dependant=yes");
	//window.showModalDialog(url, target, "top=" + windowTop + ", left=" + windowLeft + ", location=0; toolbar=0; directories=0; status=0; menubar=0; scrollbars=0; resizable=0; fullscreen=0; dialogWidth:" + windowWidth + "px; dialogHeight:" + windowHeight + "px; dependant=yes");
}

function Notice()
{
	var url = "Notice.asp";
	var target= "Notice";
	var windowHeight = 150;
	var windowWidth = 300;
	var windowTop = Math.round((screen.availHeight - windowHeight) / 2);
	var windowLeft = Math.round((screen.availWidth - windowWidth) / 2);

	//Open the Pre-Registration Page in a new fitted window.
	window.open(url, target, "top=" + windowTop + ", left=" + windowLeft + ", location=0, toolbar=0, directories=0, status=0, menubar=0, scrollbars=0, resizable=0, fullscreen=0, width=" + windowWidth + ", height=" + windowHeight + ", dependant=yes");
	//window.showModalDialog(url, target, "top=" + windowTop + ", left=" + windowLeft + ", location=0; toolbar=0; directories=0; status=0; menubar=0; scrollbars=0; resizable=0; fullscreen=0; dialogWidth:" + windowWidth + "px; dialogHeight:" + windowHeight + "px; dependant=yes");
}