// JavaScript Document
function validate_required(field,alerttxt)
{
with (field)
{
if (value==null||value=="")
  {alert(alerttxt);return false}
else {return true}
}
}

function validate_frmConfirmation(thisform)
{
with (thisform)
{
if (validate_required(txtName,"Please provide your full name.")==false)
  {txtName.focus();return false}
  
  	  	  if (validate_required(txtEnq,"Please enter your enquiry so The Queens Hotel can assist.")==false)
		  {txtEnq.focus();return false}
  
	  	 if (validate_required(txtTel,"Please provide a contact number.")==false)
	  	 {txtTel.focus();return false}
	   
		 if (validate_required(txtemail,"Please enter your email address.")==false)
		 {txtemail.focus();return false}
 
		 if (validate_required(txtAdd,"Please enter your address.")==false)
		 {txtAdd.focus();return false}
		 
		 if (validate_required(txtPostcode,"Please enter your postcode.")==false)
		 {txtPostcode.focus();return false}
		 
		 if (validate_required(txtRequirments,"Does your group have any special requirments? For example sea view accommodation if available, disabled access, special dinner menu, or maybe a bottle of bubbly for the group organizer?")==false)
		 {txtRequirments.focus();return false}
		 
		 if (agree.checked == false) { alert("Please confirm you agree with the terms and conditions of the Queens Hotel"); agree.focus(); return false; }
		  
		  
}	
}
