// JavaScript
var msAction = ""
var msCurrent = "/legislation/Login.nsf"
var moForm = null;
function OnLoad()
{
	if (!document) return;
	moForm = document._Login;
	msAction = moForm.action
}
function CurrentSub()
{
	if (!moForm || !msAction) return;
	moForm.action = msAction;
	moForm.submit();
}
function ForgottenPwd()
{
	if (!moForm || !msCurrent) return;
	if (moForm.FPUsername.value == '') {
		alert('The Email Address must be entered.');
		return 0;
	}
	moForm.action = msCurrent + "/ForgottenPwd";
	moForm.submit();
}
function NewSub()
{
	if (!moForm || !msCurrent) return;
	if (moForm.NSFirstname.value == '') {
		alert('The Firstname must be entered.');
		return 0;
	}
	if (moForm.NSLastname.value == '') {
		alert('The Lastname must be entered.');
		return 0;
	}
	if (moForm.NSEmailAddress.value == '') {
		alert('The Email Address must be entered.');
		return 0;
	}
	if (moForm.NSPassword.value == '') {
		alert('The Password must be entered.');
		return 0;
	}
	if (moForm.NSConfirm.value == '') {
		alert('The Confirm Password must be entered.');
		return 0;
	}
	if (moForm.NSPassword.value !== moForm.NSConfirm.value) {
		alert('The Password and Confirmation must be the same.');
		return 0;
	}
	moForm.action = msCurrent + "/NewSubscriber";
	moForm.submit();
}
function ShowCurrentSub()
{
	if (!currentsub || !forgotten || !newsub) return;
	currentsub.style.display = "block";
	newsub.style.display = "none";
	forgotten.style.display = "none";
}
function ShowForgotten()
{
	if (!currentsub || !forgotten || !newsub) return;
	currentsub.style.display = "none";
	newsub.style.display = "none";
	forgotten.style.display = "block";
}
function ShowNewSub()
{
	if (!currentsub || !forgotten || !newsub) return;
	currentsub.style.display = "none";
	newsub.style.display = "block";
	forgotten.style.display = "none";
}
