function chkenqfrm() {
	if (!chkgen()) return;
	df=document.form;
	if (df.Comments.length<5){alert("You haven't entered an enquiry");return;}

	c1=document.getElementById("c1").status;
	c2=document.getElementById("c2").status;
	if (!c1 && !c2) {alert("Please select preferred contact method");return;}

	if(df.Comments.value.length<10){alert("Please enter an enquiry");return;}

	str=df.Title.value+" "+df.Forename.value+" "+df.Surname.value+", you are sending an enquiry:\n";
	str+="You prefer to be contacted by ";
	if (c1) str+="telephone on "+df.Phone.value+".\n"; else str+="email at "+em+".\n";
	if (c1 && em.length>4) str+="(Alternate contact by email at "+em+".)\n";
	if (c2 && df.Phone.value.length>9) str+="(Alternate contact by phone at "+df.Phone.value+".)\n";
	str+="Your address :"+df.address1.value+", ";
	if (df.address2.value.length>1) str+=df.address2.value+", "
	str+=df.Town.value+"  "+df.Postcode.value+"\n";
	str+="\nYour enquiry: "+df.Comments.value+"\n";
	str+="\nPress OK to send your enquiry or CANCEL to change anything";
	if (!confirm(str)) return;
	
	df.action="/enqproc.php5";
	df.submit();
}

function chkcmpfrm() {
	if (!chkgen()) return;
	df=document.form;
	if (df.Answer.value.length<1){alert("You haven't entered an answer!");return;}

	c1=document.getElementById("c1").status;
	c2=document.getElementById("c2").status;
	if (!c1 && !c2) {alert("Please select preferred contact method");return;}

	str=df.Title.value+" "+df.Forename.value+" "+df.Surname.value+", you are sending an entry:\n";
	str+="You prefer to be contacted by ";
	if (c1) str+="telephone on "+df.Phone.value+".\n"; else str+="email at "+em+".\n";
	if (c1 && em.length>4) str+="(Alternate contact by email at "+em+".)\n";
	if (c2 && df.Phone.value.length>9) str+="(Alternate contact by phone at "+df.Phone.value+".)\n";
	str+="Your address :"+df.address1.value+", ";
	if (df.address2.value.length>1) str+=df.address2.value+", "
	str+=df.Town.value+"  "+df.Postcode.value+"\n";
	str+="\nYour answer: "+df.Answer.value+"\n";
	str+="\nPress OK to send your entry or CANCEL to change anything";
	if (!confirm(str)) return;
	
	df.action="/enqproc.php5";
	df.submit();
}
