function formatCheck_isValidDate(value) 
{	 var regex = /((^(10|12|0?[13578])([/])(3[01]|[12][0-9]|0?[1-9])([/])((1[8-9]\d{2})|([2-9]\d{3}))$)|(^(11|0?[469])([/])(30|[12][0-9]|0?[1-9])([/])((1[8-9]\d{2})|([2-9]\d{3}))$)|(^(0?2)([/])(2[0-8]|1[0-9]|0?[1-9])([/])((1[8-9]\d{2})|([2-9]\d{3}))$)|(^(0?2)([/])(29)([/])([2468][048]00)$)|(^(0?2)([/])(29)([/])([3579][26]00)$)|(^(0?2)([/])(29)([/])([1][89][0][48])$)|(^(0?2)([/])(29)([/])([2-9][0-9][0][48])$)|(^(0?2)([/])(29)([/])([1][89][2468][048])$)|(^(0?2)([/])(29)([/])([2-9][0-9][2468][048])$)|(^(0?2)([/])(29)([/])([1][89][13579][26])$)|(^(0?2)([/])(29)([/])([2-9][0-9][13579][26])$))/;
	 return regex.test(value);
}
function isValidDate(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is not a valid date, please re-enter in MM/DD/YYYY format.";
	 return formatCheck_isValidDate(formElement.value);
}
function formatCheck_isValidFloat(value) 
{	 var regex = /^\d*\.?\d*$/;
	 return regex.test(value);
}
function isValidFloat(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is invalid, please re-enter.";
	 return formatCheck_isValidFloat(formElement.value);
}
function formatCheck_isValidInteger(value) 
{	 var regex = /^\d+$/;
	 return regex.test(value);
}
function isValidInteger(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is invalid, please re-enter.";
	 return formatCheck_isValidInteger(formElement.value);
}
function formatCheck_isValidCurrency(value) 
{	 var regex = /^\-?\d{1,3}(,?\d{3})*\.?(\d{1,2})?$/;
	 return regex.test(value);
}
function isValidCurrency(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is not a valid dollar amount, please re-enter.";
	 return formatCheck_isValidCurrency(formElement.value);
}
function formatCheck_isValidCurrencyPositiveOrZero(value) 
{	 if (!formatCheck_isValidCurrency(value))
		 return false;
	 var regex = /^\d{1,3}(,?\d{3})*\.?(\d{1,2})?$/;
	 return regex.test(value);
}
function isValidCurrencyPositiveOrZero(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is not a valid dollar amount, please re-enter.";
	 if (!isValidCurrency(formElement))
		 return false;
	 return formatCheck_isValidCurrencyPositiveOrZero(formElement.value);
}
function formatCheck_isValidPositiveCurrency(value) 
{	 if (!formatCheck_isValidCurrencyPositiveOrZero(value))
		 return false;
	 var regex = /[1-9]/;
	 return regex.test(value);
}
function isValidPositiveCurrency(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is not a valid dollar amount, please re-enter. If value is zero, leave blank.";
	 if (!isValidCurrencyPositiveOrZero(formElement))
		 return false;
	 return formatCheck_isValidPositiveCurrency(formElement.value);
}
function formatCheck_isValidPercentageRate22(value) 
{	 if (!formatCheck_isValidFloat(value))
		 return false;
	 var regex = /^\d{0,2}(\.\d{1,2})?$/;
	 return regex.test(value);
}
function isValidPercentageRate22(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is invalid, please re-enter.";
	 if (!isValidFloat(formElement))
		 return false;
	 return formatCheck_isValidPercentageRate22(formElement.value);
}
function formatCheck_isValidPercentageRate24(value) 
{	 if (!formatCheck_isValidFloat(value))
		 return false;
	 var regex = /^\d{0,2}(\.\d{1,4})?$/;
	 return regex.test(value);
}
function isValidPercentageRate24(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is invalid, please re-enter.";
	 if (!isValidFloat(formElement))
		 return false;
	 return formatCheck_isValidPercentageRate24(formElement.value);
}
function formatCheck_isValidPercentageRate33(value) 
{	 if (!formatCheck_isValidFloat(value))
		 return false;
	 var regex = /^\d{0,3}(\.\d{1,3})?$/;
	 return regex.test(value);
}
function isValidPercentageRate33(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is invalid, please re-enter.";
	 if (!isValidFloat(formElement))
		 return false;
	 return formatCheck_isValidPercentageRate33(formElement.value);
}
function formatCheck_isValidPercentageRate32(value) 
{	 if (!formatCheck_isValidFloat(value))
		 return false;
	 var regex = /^\d{0,3}(\.\d{1,2})?$/;
	 return regex.test(value);
}
function isValidPercentageRate32(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is invalid, please re-enter.";
	 if (!isValidFloat(formElement))
		 return false;
	 return formatCheck_isValidPercentageRate32(formElement.value);
}
function formatCheck_isValidEmail(value) 
{	 var regex = /^([0-9a-zA-Z]([-.\w]*[0-9a-zA-Z])*@([0-9a-zA-Z][-\w]*[0-9a-zA-Z]\.)+[a-zA-Z]{2,9})$/;
	 return regex.test(value);
}
function isValidEmail(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is an invalid e-mail address, please re-enter.";
	 return formatCheck_isValidEmail(formElement.value);
}
function formatCheck_isValidFICO(value) 
{	 if (!formatCheck_isValidInteger(value))
		 return false;
	 var regex = /^(0|3[5-9][0-9]|[4-8][0-9][0-9]|900)$/;
	 return regex.test(value);
}
function isValidFICO(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " must be either 0, or between 350 and 900.";
	 if (!isValidInteger(formElement))
		 return false;
	 return formatCheck_isValidFICO(formElement.value);
}
function formatCheck_isValidInterestOnlyTerm(value) 
{	 if (!formatCheck_isValidInteger(value))
		 return false;
	 var regex = /^(?:0?[1-9]|1[0-9]|2[0-9]|3[0])$/;
	 return regex.test(value);
}
function isValidInterestOnlyTerm(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " must be a value between 1 - 30.";
	 if (!isValidInteger(formElement))
		 return false;
	 return formatCheck_isValidInterestOnlyTerm(formElement.value);
}
function formatCheck_isWhitespace(value) 
{	 var regex = / \t\n\r/;
	 return regex.test(value);
}
function isWhitespace(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is invalid, please re-enter.";
	 return formatCheck_isWhitespace(formElement.value);
}
function formatCheck_isValidMasterPolicyNumber(value) 
{	 var regex = /(^[a-z0-9A-z]{5}-[a-z0-9A-z]{2}$)|(^[a-z0-9A-z]{7}$)/;
	 return regex.test(value);
}
function isValidMasterPolicyNumber(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is an invalid master policy number, please re-enter in XXXXX-XX format.";
	 return formatCheck_isValidMasterPolicyNumber(formElement.value);
}
function formatCheck_isValidPhone(value) 
{	 var regex = /((^\d{3}[ \.\-]\d{3}[ \.\-]\d{4}$)|(^\d{3}\d{3}\d{4}$))/;
	 return regex.test(value);
}
function isValidPhone(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " must be in the format of XXX-XXX-XXXX.";
	 return formatCheck_isValidPhone(formElement.value);
}
function formatCheck_isValidRMICLoanNumber(value) 
{	 var regex = /(^\d{6,10}$)/;
	 return regex.test(value);
}
function isValidRMICLoanNumber(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is invalid, please re-enter.";
	 return formatCheck_isValidRMICLoanNumber(formElement.value);
}
function formatCheck_isValidSSN(value) 
{	 var regex = /((^\d{3}\-\d{2}\-\d{4}$)|(^\d{3}\d{2}\d{4}$))/;
	 return regex.test(value);
}
function isValidSSN(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is an invalid Social Security Number, please re-enter.";
	 return formatCheck_isValidSSN(formElement.value);
}
function formatCheck_isValidYear(value) 
{	 if (!formatCheck_isValidInteger(value))
		 return false;
	 var regex = /^[1-2]\d{3}$/;
	 return regex.test(value);
}
function isValidYear(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " must be a 4 digit year.";
	 if (!isValidInteger(formElement))
		 return false;
	 return formatCheck_isValidYear(formElement.value);
}
function formatCheck_isValidZIPCode(value) 
{	 var regex = /^\d{5}(( |-)?\d{4})?$/;
	 return regex.test(value);
}
function isValidZIPCode(formElement) 
{	 if (formElement.validationMessage.length == 0) 
		 formElement.validationMessage = " is an invalid Zip Code, please re-enter in 99999-9999 format.";
	 return formatCheck_isValidZIPCode(formElement.value);
}
