function fnValidate_program(f) {
	if (f.Name.value.length == 0) {
		alert('Please enter your name to continue.');
		f.Name.focus();
		return false;
	}
	if (!IsValidEmail(f.Email.value) && (f.Phone.value.length < 10 || !isNumeric(f.Phone.value))) {
		alert('Please enter a valid email address or phone number to continue.');
		f.Email.focus();
		return false;
	}
	return true;
}
function fnValidate_contact(f) {
	if (f.Name.value.length == 0) {
		alert('Please enter your name to continue.');
		f.Name.focus();
		return false;
	}
	if (!IsValidEmail(f.Email.value) && (f.Phone.value.length < 10 || !isNumeric(f.Phone.value))) {
		alert('Please enter a valid email address or phone number to continue.');
		f.Phone.focus();
		return false;
	}
	return true;
}
function fnValidate_newsletter(f) {
	if (!(f.newsletter_join.value)) {
		alert('Please enter your email address to continue.');
		f.newsletter_join.focus();
		return false;
	}
	return true;
}
function if_yes(objectID) {
	if (objectID == "equipment_other") {
		ifchecked = other_equip;
		other_equip = 1-other_equip;
	}
	dropdown(objectID,ifchecked);
}
function IsValidEmail(val) {
	var iLen = val.length;
	if 	((iLen < 6) || (val.indexOf('@') < 1) || ((val.charAt(iLen - 3) != '.') && (val.charAt(iLen - 4) != '.') && (val.charAt(iLen - 5) != '.')) ) return false;
	return true;
}
function isNumeric(val) {
	var ValidChars = "0123456789.-()";
	for (i=0; i<val.length; i++) if (ValidChars.indexOf(val.charAt(i)) == -1) return false;
	return true;
}
function establishDOM(objectID) {
	if (document.getElementById) return (document.getElementById(objectID).style);
	else return (0);
}
function dropdown(objectID,stat) {
	idx=establishDOM(objectID);
	if (idx) idx.display = (stat) ? "block" : "none";
}
other_equip=0;
