// JavaScript Document


function open_new(url,w,h){
	open_new(url,w,h,'yes');
}
function open_new(url,w,h,s) { 
nPopUp = window.self.open("","_blank","toolbar=no,location=no,directories=no,status=no,scrollbars=no,resizable=no,copyhistory=no,width="+w+",height="+h);
ndoc = nPopUp.document;
ndoc.close();
ndoc.open();
atrs = '<HTML><HEAD><TITLE>SantaFe ..</TITLE></HEAD>';
atrs+= '<BODY BGCOLOR="white" LEFTMARGIN=0 TOPMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0>';
atrs+= "<A HREF='javascript:self.close()'><IMG SRC='"+url+"' BORDER=0></A>";
atrs+= "</BODY></HTML>";
ndoc.write(atrs);
ndoc.close();
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function checkIt(el) {
if (el.value == "PIO_Yes") {
document.getElementById('text').style.display = "block";
}
else {
document.getElementById('text').style.display = "none";
document.getElementById('pio').value = '';
}
}

function checkHolder(e1) {
	if(e1.value=="Joint")
	{
		document.getElementById("jntname").readOnly = false;
		document.getElementById("jntage").readOnly = false;
		document.getElementById("relation").readOnly = false;
	}
	else if(e1.value=="Single"){
	document.getElementById("jntname").readOnly = true;
	document.getElementById("jntage").readOnly = true;
		document.getElementById("relation").readOnly = true;
		//document.form1.jointworking.enabled = true;
		document.getElementById('jointworking').style.display = "none";
		}
	}

function checkOnload() {
	document.getElementById("jntname").readOnly = true;
	document.getElementById("jntage").readOnly = true;
		document.getElementById("relation").readOnly = true;
		document.getElementById("jointworking").checked = false;
}

function validate(){
    if (document.form1.tbfname.value=="")
    {
      alert("Please Enter Name " );
      document.form1.tbfname.focus();
      return false;
    }
	if (document.form1.tbcity.value=="")
    {
      alert("Please Enter City Name " );
      document.form1.tbcity.focus();
      return false;
    }
	if (document.form1.tbcountry.value=="")
    {
      alert("Please Enter Country " );
      document.form1.tbcountry.focus();
      return false;
    }
	if (document.form1.nationality.value=="")
    {
      alert("Please Enter Nationality " );
      document.form1.nationality.focus();
      return false;
    }
	if (document.form1.txtcontactno.value=="")
    {
      alert("Please Enter Contact No." );
      document.form1.txtcontactno.focus();
      return false;
    }
 if (document.form1.tbemail.value=="")
    {
      alert("Please enter your Email Id" );
      document.form1.tbemail.focus();
      return false;
    }

	
}