function toggleCheckBox(argCheckBoxId) {
	document.getElementById(argCheckBoxId).checked = !(document.getElementById(argCheckBoxId).checked);
}

function toggleRadio(argRadioId) {
	if (document.getElementById(argRadioId).checked == false) {
		document.getElementById(argRadioId).checked = !(document.getElementById(argRadioId).checked);
	}
}


function toggleCheckBoxStyle(argCheckBoxTextId) {
	if (document.getElementById(argCheckBoxTextId).style.textDecoration != "underline") {
		document.getElementById(argCheckBoxTextId).style.textDecoration = "underline";
		document.getElementById(argCheckBoxTextId).style.color = "#867A77";
	} else {
		document.getElementById(argCheckBoxTextId).style.textDecoration = "none";
		document.getElementById(argCheckBoxTextId).style.color = "#666666";
	}
}

function validateForm() {
	if (document.registerForm.fUserName.value=="") {
		alert("Please provide your name.");
		document.registerForm.fUserName.focus();
		return false;
	}
	
	/*if (document.registerForm.fUserPWD.value=="") {
		alert("Please provide your password.");
		document.registerForm.fUserPWD.focus();
		return false;
	}
	*/
	if (document.registerForm.fUserEmail.value=="") {
		alert("Please provide your email address.");
		document.registerForm.fUserEmail.focus();
		return false;
	}
	
	if (document.registerForm.fUserEmail.value!=document.registerForm.fUserEmailCheck.value) {
		alert("Please verify that your email address is correct in both fields.");
		document.registerForm.fUserEmail.focus();
		document.registerForm.fUserEmail.style.backgroundColor = "#ffffcc";
		document.registerForm.fUserEmailCheck.style.backgroundColor = "#ffffcc";
		return false;
	} else {
		document.registerForm.fUserEmail.style.backgroundColor = "#ffffff";
		document.registerForm.fUserEmailCheck.style.backgroundColor = "#ffffff";
	}
	
	
	if (document.registerForm.fUserEmail.value.indexOf("@") == -1) {
		alert("Email address must contain an @.");
		document.registerForm.fUserEmail.focus();
		return false;
	}
	
	if (document.registerForm.fUserEmail.value.indexOf(".") == -1) {
		alert("Email address must contain a dot (.)");
		document.registerForm.fUserEmail.focus();
		return false;
	}
	
	/*
	if (document.registerForm.fAddressStreet.value=="") {
		alert("Please provide your street address.");
		document.registerForm.fAddressStreet.focus();
		return false;
	}
	
	if (document.registerForm.fAddressCity.value=="") {
		alert("Please provide your city.");
		document.registerForm.fAddressCity.focus();
		return false;
	}
	
	if (document.registerForm.fAddressState.value=="") {
		alert("Please provide your state.");
		document.registerForm.fAddressState.focus();
		return false;
	}
	*/
	if (document.registerForm.fAddressZip.value=="") {
		alert("Please provide your zip code.");
		document.registerForm.fAddressZip.focus();
		return false;
	}
	
	return true;
}
