function valJobApplyForm(){
 
	var why1 = "";
	
	if(document.jobApplyForm.firstname.value == ""){
	 why1+='Please Enter your Firstname<br/>';	
 	 }
	 
	 if(document.jobApplyForm.lastname.value == ""){
	 why1+='Please Enter your Lastname <br/>';	
 	 }
	 
	 if(isEmail(document.getElementById("emailaddress").value)==false){
		why1+='Please enter valid Email address <br/>';
	}
	
	 
	 if(document.jobApplyForm.contactphone.value == ""){
	 why1+='Please enter your Contact Phone <br/>';	
	 
	 }
	 
	  if(document.jobApplyForm.myresume.value == ""){
	 why1+='Please attach your resume <br/>';	
	 
	 }
	 
	   if(document.jobApplyForm.cover_note[0].checked){
		    if(document.jobApplyForm.covernoteAttach.value == ""){
				 why1+='Please attach your cover note <br/>';	
			}
			
	 
	 }
	  if(document.jobApplyForm.cover_note[1].checked){
		    if(document.jobApplyForm.covernoteText.value == ""){
				 why1+='Please enter your cover note text <br/>';	
			}
			
	 
	 }
	 
	
	 if(why1!="")
		{
		 
		 
		showDialog('Job Apply',why1,'warning');
		return false;
		
		}
 
}
 

function  gotofocus()
{
		
	if(document.jobApplyForm.firstname.value==""){
 		document.jobApplyForm.firstname.focus();
	}
	
	else if(document.jobApplyForm.lastname.value=="")	
	document.jobApplyForm.lastname.focus();
	
	else if(isEmail(document.getElementById("emailaddress").value)==false){	
	document.jobApplyForm.emailaddress.focus();
	}
	
	 else if(document.jobApplyForm.contactphone.value == ""){
	 document.jobApplyForm.contactphone.focus();
	 
	 }
	 
	 else if(document.jobApplyForm.myresume.value == ""){
	 document.jobApplyForm.myresume.focus();
	 
	 }
	
	 else if(document.jobApplyForm.cover_note[0].checked){
		    if(document.jobApplyForm.covernoteAttach.value == ""){
				 document.jobApplyForm.covernoteAttach.focus();
			}
			
	 
	 }
	 else if(document.jobApplyForm.cover_note[1].checked){
		    if(document.jobApplyForm.covernoteText.value == ""){
				 document.jobApplyForm.covernoteText.focus();	
			}
			
	 
	 }

}

function isEmail(strValue) {

 var objRegExp = /^[a-z]\w*([.\-]\w+)*@[a-z]\w*([.\-]\w+)*\.[a-z]{2,3}$/i;

 return objRegExp.test(strValue);

}

function fnkeywords()
{
	document.getElementById("keywords").value = "";
}
function fnSubSearchForm()
{
	 
	document.jobsearchForm.submit();
	return true;
}



