function validateQuick(f){
	e=0;
    d=document;
    tn=f['FormName'];te=f['FormEmail'];tp=f['FormPhone'];
	if(te.value=='' && tp.value==''){
		e++;
		hl('lblEmail',true);
		hl('lblPhone',true);
	} else {
		hl('lblEmail',false);
		hl('lblPhone',false);		
	}
	if(tn.value==''){
		e++;
		hl('lblName',true);
	} else {
		hl('lblName',false);
	}
	if(e<=0){
		return true;
	} else {
		alert('Please enter your name and either an email or phone number.');
		return false;
	}
}
function validateMain(f){
	e=0;
    d=document;
    tn=f['FormName'];te=f['FormEmail'];tp=f['FormPhone'];tc=f['FormMessage'];
	if(tn.value==''){
		e++;
		hl('lblName',true);
	} else {
		hl('lblName',false);
	}
    if(te.value==''){
		e++;
		hl('lblEmail',true);
	} else {
		hl('lblEmail',false);
	}
    if(tc.value==''){
		e++;
		hl('lblMessage',true);
	} else {
		hl('lblMessage',false);
	}
	if(e<=0){
		return true;
	} else {
		alert('Please enter the required fields.');
		return false;
	}
}
function validatePreQual(f){
	e=0;
    d=document;
    tn=f['FormName'];te=f['FormEmail'];tp=f['FormPhone'];ta=f['FormAddress1'];tc=f['FormCity'];tz=f['FormZip'];ts=f['FormSsn'];
    tim=f['FormIncomemonthly'];tpc=f['FormPmtcar'];tpcc=f['FormPmtcc'];
    if(tim.value==''){
		e++;
		hl('lblIncome',true);
	} else {
		hl('lblIncome',false);
	}
    if(tpc.value==''){
		e++;
		hl('lblCar',true);
	} else {
		hl('lblCar',false);
	}
    if(tpcc.value==''){
		e++;
		hl('lblCC',true);
	} else {
		hl('lblCC',false);
	}
	if(tn.value==''){
		e++;
		hl('lblName',true);
	} else {
		hl('lblName',false);
	}
    if(te.value==''){
		e++;
		hl('lblEmail',true);
	} else {
		hl('lblEmail',false);
	}
    if(tp.value==''){
		e++;
		hl('lblPhone',true);
	} else {
		hl('lblPhone',false);
	}
    if(ta.value==''){
		e++;
		hl('lblAddress1',true);
	} else {
		hl('lblAddress1',false);
	}
    if(tc.value==''){
		e++;
		hl('lblCity',true);
	} else {
		hl('lblCity',false);
	}
    if(tz.value==''){
		e++;
		hl('lblZip',true);
	} else {
		hl('lblZip',false);
	}
    if(ts.value==''){
		e++;
		hl('lblSsn',true);
	} else {
		hl('lblSsn',false);
	}
	if(e<=0){
		return true;
	} else {
		alert('Please enter the required fields.');
		return false;
	}
}
function hl(el,t){
	el = document.getElementById(el);
	el.style.color=(t)?'#990000':'#333333';
}