function checkfield(loginform)
{
	ok=true
	var test=document.getElementById("hiddenvalue").value;
	if(loginform.name.value=="")
	{
		alert("Please Enter Your Name.")
		loginform.name.focus()
		ok=false
	}
	 else if((loginform.email.value.indexOf('@') == -1) || (loginform.email.value.indexOf('.') == -1))
	    {
	 	alert("please enter valid email address in the form: yourname@doaminname.com")
	 	loginform.email.value='';
		 loginform.email.focus();
		 ok=false
		 }
		 else if(loginform.mobile.value=="")
	{
		alert("Please Enter Mobile Number.")
		loginform.mobile.focus()
		ok=false
	}
		  else if(loginform.date.value=="")
	{
		alert("Please Enter Date of Journey.")
		loginform.date.focus()
		ok=false
	}
	   else if(loginform.person.value=="")
	{
		alert("Please Enter Mo. of Person.")
		loginform.person.focus()
		ok=false
	}
	 
	
	
	  	else if (loginform.need.value == "")
	{
		alert("Please Specify Your Requirements.");
		loginform.need.focus();
		ok=false
	}
	else if(loginform.validation.value=="")
	{
		alert("Please Enter The Validation Code.");
		loginform.validation.focus();
		ok=false;
	}
	else if(loginform.validation.value!=test)
	{
		alert("Please Enter The Correct Code.");
		loginform.validation.focus();
		ok=false;
	}
	return ok
}

function ValidateNum(input,event){
			var keyCode = event.which ? event.which : event.keyCode;
			if(parseInt(keyCode)>=48 && parseInt(keyCode)<=57){
				return true;
			}
			return false;
		}
		
	
function lockcode()
{
var zz=new Array();
			
			 zz[0]=get_random();
			 zz[1]=get_random();
			 zz[2]=get_random();
			 zz[3]=get_random();
			 zz[4]=get_random(); 
			var xx=""+zz[0]+zz[1]+zz[2]+zz[3]+zz[4];
			
			document.write('<div id="apDiv1"><input type=hidden  name=hiddenvalue id=hiddenvalue value='+xx+' />');
			document.write('<img  style=\"height:18px;width:18px;\" src=image/'+zz[0]+'.gif /><img style=\"height:18px;width:18px;\"  src=image/'+zz[1]+'.gif /><img  style=\"height:18px;width:18px;\"  src=image/'+zz[2]+'.gif /><img style=\"height:18px;width:18px;\"  src=image/'+zz[3]+'.gif /><img style=\"height:18px;width:18px;\"  src=image/'+zz[4]+'.gif /></div>');
			
}
function get_random()
{

    var xx=null;
	var yy='xzc';
	
	xx=Math.floor(Math.random()*9);
	return xx;
	
}