function validateEnquiry()
{
	var x=document.frmEnquiry;
	if(x.txtName.value=='')
	{
		alert("Enter Client Name !");
		x.txtName.focus();
		return false;
	}
	if(x.txtNation.value=='')
	{
		alert("Enter Nationality !");
		x.txtNation.focus();
		return false;
	}
	if(x.txtEmail.value=='')
	{
		alert("Enter Email ID !");
		x.txtEmail.focus();
		return false;
	}
	if(x.txtEmail.value != '')
	{
		var aa=x.txtEmail.value;
	apos=aa.indexOf("@")
	dotpos=aa.lastIndexOf(".")
	if (apos<1||dotpos-apos<2) 
  		{
 		 alert("Invalid mail-ID !");
 		 x.txtEmail.focus();
 		 return false;
 		}
	}
	if(x.txtSDate.value=='')
	{
		alert("Enter Starting Date !");
		x.txtSDate.focus();
		return false;
	}
	if(x.txtFDate.value=='')
	{
		alert("Enter Finishing Date !");
		x.txtFDate.focus();
		return false;
	}
	if(x.txtVehicle.value=='')
	{
		alert("Enter Type of Vehicle needed !");
		x.txtVehicle.focus();
		return false;
	}
	if(x.txtAdult.value=='')
	{
		alert("Enter Number of Adults !");
		x.txtAdult.focus();
		return false;
	}	
	if(x.txtChildren.value=='')
	{
		alert("Enter Number of Child !");
		x.txtChildren.focus();
		return false;
	}
	if(x.txtRooms.value=='')
	{
		alert("Enter Number of Rooms wanted !");
		x.txtRooms.focus();
		return false;
	}/*
	if(x.chkDelux.value=='' or x.chk5.value=='' or x.chk4.value=='')
	{
		alert("Type of Hotel facility wanted !");
		x.chkDelux.focus();
		return false;
	}*/
	select_one_checkbox();
	return true;
}

/*
function checkAll(field)
{
	// for un-n-checking all the check boxes
	if(document.frmEnquiry.checkbox.checked==true)
	{
		for (i = 0; i < field.length; i++)
		field[i].checked = true ;
		return false;
	}
	else
	{
		for (i = 0; i < field.length; i++)
		field[i].checked = false ;
		return false;
	}
	return true;
}
*/

function select_one_checkbox() 
{ 
 var flag=0;
    // loop through all elements
    for (i=0; i<document.frmEnquiry.length; i++) 
    {
      // Look for our checkboxes only
        if (document.frmEnquiry.elements[i].name.indexOf("chkHotel")==-1) 
        { //alert("Look for our checkboxes only")
            // If any are checked then confirm alert, otherwise nothing happens
            if(document.frmEnquiry.elements[i].checked) 
            {		//alert("If any are checked then confirm alert, otherwise nothing happens")
                flag++;
                //return confirm ('Are you sure you want to copy your selection(s)?')
            }
        }
   }
   if(flag==0)
	{
    	alert ('Select Category of Hotel !')
    	return false;
	}
	return true;
}