//Verify Contact Form
function verify_cnt() {
var txt = "";
	
	if (document.frmcnt.title.value=="") {
	 txt = txt + "\n * Title";
	}
	if (document.frmcnt.name.value=="") {
	 txt = txt + "\n * Name";
	}
	var str=document.frmcnt.email.value
	var filter=/^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i 
	if (!filter.test(str)) {
	 txt = txt + "\n * Email (Valid!)";
	}
	if (document.frmcnt.telephone.value=="") {
	 txt = txt + "\n * Telephone";
	}
	if (document.frmcnt.message.value=="") {
	 txt = txt + "\n * Message";
	}
	if (txt) {
		alert ("The folowing fields are required:\n" + txt);
		return false;
	}	
}

//Verify Tell A Friend
function veifytlfr() {
var txt = "";
	
	if (document.frmtlfr.yourname.value=="") {
	 txt = txt + "\n * Your Name";
	}
	
	var str=document.frmtlfr.youremail.value
	var filter=/^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i 
	if (!filter.test(str)) {
	 txt = txt + "\n * Your Email (Valid!)";
	}
	
	if (document.frmtlfr.recname.value=="") {
	 txt = txt + "\n * Recipient Name";
	}
	var str=document.frmtlfr.recemail.value
	var filter=/^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i 
	if (!filter.test(str)) {
	 txt = txt + "\n * Recipient Email (Valid!)";
	}


	if (txt) {
		alert ("The folowing fields are required:\n" + txt);
		return false;
	}	
}

//Verify Viewing Trip Form
function verifyviewtr() {
var txt = "";
	
	for(var i = 0; i < document.frmviewtr.title.length; i++) {
	if(document.frmviewtr.title[i].selected) {
		if(document.frmviewtr.title[i].value=="") {
		  txt = txt + "\n * Title";
		}
	}
	}
	if (document.frmviewtr.name.value=="") {
	 txt = txt + "\n * Name";
	}
	if (document.frmviewtr.telephone.value=="") {
	 txt = txt + "\n * Telephone";
	}
	var str=document.frmviewtr.email.value
	var filter=/^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i 
	if (!filter.test(str)) {
	 txt = txt + "\n * Email (Valid!)";
	}
	if (document.frmviewtr.address.value=="") {
	 txt = txt + "\n * Address";
	}
	if (document.frmviewtr.fromdate.value=="") {
	 txt = txt + "\n * Preferred date of travel - From";
	}
	if (document.frmviewtr.todate.value=="") {
	 txt = txt + "\n * Preferred date of travel - To";
	}
	if (document.frmviewtr.dep_air.value=="") {
	 txt = txt + "\n * Preferred departure airport?";
	}
	for(var i = 0; i < document.frmviewtr.ref_entry.length; i++) {
	if(document.frmviewtr.ref_entry[i].selected) {
		if(document.frmviewtr.ref_entry[i].value=="") {
		  txt = txt + "\n * Where did you hear about us";
		}
	}
	}
	if (txt) {
		alert ("The folowing fields are required:\n" + txt);
		return false;
	}	
}

//Verify Newsletter
function verigynewsll() {
var txt = "";
	
	var str=document.frmnewsl.email.value
	var filter=/^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i 
	if (!filter.test(str)) {
	 txt = txt + "\n * Email (Valid!)";
	}

	if (txt) {
		alert ("The folowing fields are required:\n" + txt);
		return false;
	}	
}