// JavaScript Document
function __fncCheckSaveDetails(){
	if(thisForm.txtName.value==''){
		alert('Please enter your name');thisForm.txtName.focus();return;
	}
	if(thisForm.txtEmail.value==''){
		alert('Please enter e-mail address');thisForm.txtEmail.focus();return;
	}
	if(!__fncCheckEMail(thisForm.txtEmail.value, 'Invalid E-mail Address')){ thisForm.txtEmail.focus(); return;}
	if(thisForm.txtOfficePhone.value==''){
		alert('Please enter office phone number');thisForm.txtOfficePhone.focus();return;
	}
	if(isNaN(thisForm.txtOfficePhone.value)){
		alert('Please enter valid phone number');thisForm.txtOfficePhone.focus();return;
	}
	if(thisForm.txtYahoo.value!=''){
		if(!__fncCheckEMail(thisForm.txtYahoo.value, 'Invalid Yahoo E-mail Address')){ thisForm.txtYahoo.focus(); return;}
	}
	if(thisForm.txtMSN.value!=''){
		if(!__fncCheckEMail(thisForm.txtMSN.value, 'Invalid MSN E-mail Address')){ thisForm.txtMSN.focus(); return;}
	}
	if(thisForm.txtGtalk.value!=''){
		if(!__fncCheckEMail(thisForm.txtGtalk.value, 'Invalid GMAIL E-mail Address')){ thisForm.txtGtalk.focus(); return;}
	}
	if(thisForm.txtOrganization.value==''){
		alert('Please enter organization name');thisForm.txtOrganization.focus();return;
	}
	if(thisForm.txtAddress.value==''){
		alert('Please enter address');thisForm.txtAddress.focus();return;
	}
	if(thisForm.txtCity.value==''){
		alert('Please enter your city');thisForm.txtCity.focus();return;
	}
	thisForm.txtWhat2Do.value='SAVERAQ';
	thisForm.submit();
}
function __fncCheckEMail(email, strMessage){
	var filter=/^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i
	if (filter.test(email)){
		testres=true
		return(testres)
	}else{
		alert(strMessage);
		testres=false
		return(testres)
	}
}