<?
session_start();
if(strlen($brcode)<=0)
{
 print "<script> alert('Session timed out'); parent.document.location='../ind.php'; </script>";
 return;
}

include("../opendb.php");
if($pswd=='pay' && $edit)
{
$re=mysqli_query($db,"select * from empmaster where empcode='$code'")or die(mysqli_error());
$erow=mysqli_fetch_array($re);
}
?>
<form action='<?print $PHP_SELF?>' method='post'>
<input type=hidden name='code' value='<?print $code?>'>
Eneter Password: <input type=password name='pswd'>
<input type=submit name='edit' value='Edit'>
</form>

<head>
<style>
body,td{font-family:'arial narrow';letter-spacing:1;}
tr{background-color:e3ecd2}
th{background-color:c1d799}
.mnu{margin-left:5}
body{BACKGROUND-COLOR:fcfff1}
</style>
<script>
function chkey(abc)
{
 yy=abc.value
 if(yy.indexOf('  ')>-1) 
  {
    alert('Multiple space is not allowed');
    abc.value='';
  }
 if(yy.indexOf("'")>-1) 
  {
    alert("\' is not allowed");
    abc.value='';
  }
 if(yy.indexOf("&")>-1) 
  {
    alert("& is not allowed");
    abc.value='';
  }
}

 function valid()
  {
     if(document.f1.empname.value.length<=0)
     {
       alert('Invalid Employee name');
       return false;
     }
   }
</script>
</head>


<center>
<form action='updemp.php' name=f1 method='post' onSubmit="return valid()">
<input type=hidden name='empcode' value='<?print $erow[0]?>'>
<table>
<th colspan=6 bgcolor="#C1D799">EDIT EMPLOYEE MASTER</th>
<tr><td>Trainee </td><td><select name='trainee'>
<option><?print $erow[trainee]?></option>
<option>No</option>
<option>Yes</option>
</select>
P Tax <select name='ptax'>
<option><?print $erow[ptax]?></option>
<option>No</option>
<option>Yes</option>
</select>
</td>
<td colspan=2>Select Group </td><td><select name='grp'>
<option><?print $erow[grp]?></option>
<?
 $tbl='esipfgrp'.$brcode;
$re=mysqli_query($db,"select * from $tbl order by grp")or die(mysqli_error());
while($row=mysqli_fetch_array($re))
{
 print "\n<option>$row[0]</option>";
}
?>
</select></td></tr>

</tr>

<tr><td>Division</td><td colspan=5>
<select name='divi'>
<option><?print $erow[divi]?></option>
<?
$re=mysqli_query($db,"select * from divmast where brcode='$brcode'");
while($ro=mysqli_fetch_array($re))
{
 print "\n<option>$ro[divname]</option>";
}
?>
</select>
Branch <select name='br'>
<option><?print $erow[br]?></option>
<?
$re=mysqli_query($db,"select * from br_master where brcode='$brcode'");
while($ro=mysqli_fetch_array($re))
{
 print "\n<option>$ro[brname]</option>";
}
?>
</select>
Department <select name='dept'>
<option><?print $erow[dept]?></option>
<?
$re=mysqli_query($db,"select * from deptmast where brcode='$brcode' order by deptname");
while($ro=mysqli_fetch_array($re))
{
 print "\n<option>$ro[deptname]</option>";
}
?>
</select>
</td></tr>
<tr><td>
Emp ID </td><td> <input type=text name='empid' value='<?print $erow[empid]?>'></td>
<td colspan=4><font color=red>Loss of Pay 
<?
if($erow[lop]=='y')
 print "<input type = checkbox name='lop' value='y' checked >";
else
 print "<input type = checkbox name='lop' value='y'>";
?>
Inc in Pay Roll <select name='apinpay'>
<?if($erow[apinpay]=='Y')
 print "<option>Y</option>";
  else
   print "<option>N</option>";
?>
<option>Y</option>
<option>N</option>
</select>

</td>
</tr>

<tr><td><font color='dark brown'>Emp Name</td>
<td><input type=text name='empname' size=40 value='<?print $erow[empname]?>' onKeyDown=chkey(this) ></td>
    <td>Sex </td><td colspan=2>
<select name='sex'>
<option><?print $erow[sex]?></option>
<option value='M'>Male</option>
<option value='F'>Female</option>
</select></td></tr>
<tr>
    <td colspan=2>
<?
$dob=explode('-',$erow[dob]);
?>
Dob dd<input type=text name='d' size=2 value='<?print $dob[2]?>'>
			      mm<input type=text name='m' size=2 value='<?print $dob[1]?>'>
			      yy<input type=text name='y' size=4 value='<?print $dob[0]?>'></td>
<td colspan=3>
<?
$doba=explode('-',$erow[dobactual]);
?>

Dob Actual dd<input type=text name='dac' size=2 value='<?print $doba[2]?>'>
			      mm<input type=text name='mac' size=2 value='<?print $doba[1]?>'>
			      yy<input type=text name='yac' size=4 value='<?print $doba[0]?>'></td></td>
</tr>

<tr><td>Fathers Name</td><td><input type=text name='faname' size=40 value='<?print $erow[fname]?>'></td>
    <td colspan="2">Permanent Address </td>
    <td colspan="2"><textarea rows="1" cols="25" name="peraddr"><?print $erow[peraddr]?></textarea></td>
</tr>

<tr><td>Present Address</td><td><textarea rows="1" cols="39" name="praddr"><?print $erow[praddr]?></textarea></td>
    <td colspan="2"> Designation </td>
    <td colspan="2"><input type=text name='design' size=25 value='<?print $erow[design]?>'></td>
</tr>
<tr>
<td colspan=6>Phone Res. <input type=text name='resph' value='<?print $erow[resph]?>'> 
Mob <input type=text name='mob' value='<?print $erow[mob]?>'>
Email <input type=text name='email' size=30 value='<?print $erow[email]?>'>
</tr>
<tr>
<tH colspan=12 align=center> ICE FILE DETAILS</TD>
<TR><TD colspan=12 align=center>
   <table  cellspacing=1 cellpadding=1 bgcolor=red>
	<tr bgcolor='ivory'><td align=center>Name</td><td align=center>Relationship</td><td align=center>Address & Email</td><td align=center>Phone</td><td align=center>Mobile</td></tr>
	<tr><td><input type=text name='icename1' value='<?print $erow[icename1]?>'></td>
	    <td><input type=text name='icerel1' value='<?print $erow[icerel1]?>'>	</td>
	    <td><textarea name='iceaddr1' cols=25><?print $erow[iceaddr1]?></textarea></td>
	    <td><input type=text name='icephone1' size=15 value='<?print $erow[icephone1]?>'></td>
	    <td><input type=text name='icemob1' size=15 value='<?print $erow[icemob1]?>'>	</td>
	</TR>
	<tr><td><input type=text name='icename2' value='<?print $erow[icename2]?>'></td>
	    <td><input type=text name='icerel2' value='<?print $erow[icerel2]?>'>	</td>
	    <td><textarea name='iceaddr2' cols=25><?print $erow[iceaddr2]?></textarea></td>
	    <td><input type=text name='icephone2' size=15 value='<?print $erow[icephone2]?>'></td>
	    <td><input type=text name='icemob2' size=15 value='<?print $erow[icemob2]?>'>	</td>
	</TR>


</table>
</tr>
<tr>
<tH colspan=12 align=center> OTHER DETAILS</Th>
<?
$doj=explode('-',$erow[doj]);
?>
<tr><td>Date of Join</td><td>dd<input type=text name='dj' size=2 value='<?print $doj[2]?>'>
			      mm<input type=text name='mj' size=2 value='<?print $doj[1]?>'>
			      yy<input type=text name='yj' size=4 value='<?print $doj[0]?>'></td>
    <td colspan="2"> Probation End Date&nbsp; </td>
<?
$doj=explode('-',$erow[probdate]);
?>
    <td colspan="2">dd<input type=text name='pd' size=2 size=2 value='<?print $doj[2]?>'>
			      mm<input type=text name='pm' size=2 size=2 value='<?print $doj[1]?>'>
			      yy<input type=text name='py' size=4 size=2 value='<?print $doj[0]?>'></td>
</tr>
<?
$doj=explode('-',$erow[doconf]);
?>
<tr><td>Date of Confirmation</td><td>dd<input type=text name='cd' size=2 value='<?print $doj[2]?>'>
			      mm<input type=text name='cm' size=2 value='<?print $doj[1]?>'>
			      yy<input type=text name='cy' size=4 value='<?print $doj[0]?>'></td>
    <td colspan="2"> Date of Retirement </td>
<?
$doj=explode('-',$erow[doret]);
?>
    <td colspan="2">dd<input type=text name='rd' size=2 value='<?print $doj[2]?>'>
			      mm<input type=text name='rm' size=2 value='<?print $doj[1]?>'>
			      yy<input type=text name='ry' size=4 value='<?print $doj[0]?>'></td>
</tr>

<tr><td colspan="6">ESI No &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<input type=text name='esi' size=22 value='<?print $erow[esi]?>'> 
PF No <input type=text name='pf' size=22 value='<?print $erow[pf]?>'>
PAN No. <input type=text name='pan' value='<?print $erow[pan]?>'>
</td>
</tr>

<tr><td>Blood Group</td><td><select name='bgrp' size="1">
<option><?print $erow[bgrp]?> </option>
	<option>A+</option>
          <option>A-</option>
          <option>B+</option>
          <option>B-</option>
          <option>AB+</option>
          <option>AB-</option>
          <option>O+</option>
          <option>O-</option>
        </select> 
  </td>
   <td>EmType</td><td><select name='emtype' size="1">
<option><?print $erow[emtype]?> </option>
        <option>Normal</option>
          <option>Secondary</option>
                  </select> 
  </td>
    <td>Increment Month</td><td><select name='incmon' size="1">
    <option><?print $erow[incmonth]?> </option>
	<option>1</option>
          <option>2</option>
          <option>3</option>
          <option>4</option>
          <option>5</option>
          <option>6</option>
          <option>7</option>
          <option>8</option>
          <option>9</option>
          <option>10</option>
          <option>11</option>
          <option>12</option>

        </select> 
  </td>
</tr>

<tr><td>Driving Licence M/C</td><td colspan="5"><font color="#999999">&nbsp;
        License
        No&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Date of
        Expiry&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Type</font><font color="#C0C0C0"><br>
        </font><input type=text name=drvno1 size="23" value='<?print $erow[drvno1]?>'>&nbsp;&nbsp; 
<input type=text name=drvdate1 size="19" value='<?print $erow[drvdate1]?>'> &nbsp;
        <select name='drvtype1' size="1">
	<option><?print $erow[drvtype1]?></option>
          	<option>None</option>          
		<option>Learning</option>
          <option>Two wheeler</option>
          <option>Three wheeler</option>
          <option>Four wheeler</option>
          <option>HMV</option>
          <option>International</option>
<option>LMV</option>
          </select> </td>
</tr>
<tr>
  <td>Driving Licence LMV</td><td colspan="5"><font color="#999999">&nbsp;
        License
        No&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Date of
        Expiry&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Type</font><font color="#C0C0C0"><br>
        </font><input type=text name=drvno2 size="23"  value='<?print $erow[drvno2]?>'>&nbsp;&nbsp; 
         <input type=text name=drvdate2 size="19" value='<?print $erow[drvdate1]?>'>&nbsp;
        <select name='drvtype2' size="1">
	<option><?print $erow[drvtype2]?></option>
	<option>None</option>          
	<option>Learning</option>
          <option>Two wheeler</option>
          <option>Three wheeler</option>
          <option>Four wheeler</option>
          <option>HMV</option>
          <option>International</option>
<option>LMV</option>
          </select> </td>
</tr>
<tr>
  <td>Driving Licence HGMV</td><td colspan="5"><font color="#999999">&nbsp;
        License
        No&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Date of
        Expiry&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Type</font><font color="#C0C0C0"><br>
        </font><input type=text name=drvno3 size="23"  value='<?print $erow[drvno3]?>'>&nbsp;&nbsp;
 <input type=text name=drvdate3 size="19"  value='<?print $erow[drvdate3]?>'>&nbsp;
        <select name='drvtype3'  size="1">
          <option><?print $erow[drvtype3]?></option>
	<option>None</option>          
	  <option>Learning</option>
          <option>Two wheeler</option>
          <option>Three wheeler</option>
          <option>Four wheeler</option>
          <option>HMV</option>
          <option>International</option>
<option>LMV</option>
          </select> </td>
</tr>

<tr><td>Insurance 1</td><td colspan="5"><font color="#999999">Name </font><font color="#999999">
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Date of Maturity&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Type</font><font color="#C0C0C0"><br>
        </font><input type=text name=insurname1 size="23"  value='<?print $erow[insurname1]?>'>
&nbsp;&nbsp; <input type=text name=insurdate1 size="19"value='<?print $erow[insurdate1]?>'>&nbsp;
        <select name='insurtype1'  size="1">
	 <option><?print $erow[insurtype1]?></option>
          <option>Life Insurance</option>
          <option>Mediclaime</option>
<option>Accident Policy</option>
          </select> </td>
</tr>
<tr>
  <td>Insurance 2</td><td colspan="5"><font color="#999999">Name </font><font color="#999999">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Date of Maturity&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Type</font><font color="#C0C0C0"><br>
        </font><input type=text name=insurname2 size="23"  value='<?print $erow[insurname2]?>'>&nbsp;&nbsp;
	 <input type=text name=insurdate2 size="19"  value='<?print $erow[insurdate2]?>'>&nbsp;
        <select name='insurtype2' size="1">
	<option><?print $erow[insurtype2]?></option>
          <option>Life Insurance</option>
          <option>Mediclaime</option>
<option>Accident Policy</option>

          </select> </td>
</tr>
<tr>
  <td>Insurance 3</td><td colspan="5"><font color="#999999">Name </font><font color="#999999">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Date of Maturity&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Type</font><font color="#C0C0C0"><br>
        </font><input type=text name=insurname3 size="23" value='<?print $erow[insurname3]?>'>
&nbsp;&nbsp; <input type=text name=insurdate3 size="19" value='<?print $erow[insurdate3]?>'>&nbsp;
        <select name='insurtype3'  size="1">
	<option><?print $erow[insurtype3]?></option>
          <option>Life Insurance</option>
          <option>Mediclaime</option>
<option>Accident Policy</option>

          </select> </td>
</tr>
<tr>
  <td>Insurance 4</td><td colspan="5"><font color="#999999">Name </font><font color="#999999">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Date of Maturity&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        Type</font><font color="#C0C0C0"><br>
        </font><input type=text name=insurname4 size="23">&nbsp;&nbsp; <input type=text name=insurdate4 size="19">&nbsp;
        <select name='insurtype4' size="1">
	<option><?print $erow[insurtype4]?></option>
          <option>Life Insurance</option>
          <option>Mediclaime</option>
<option>Accident Policy</option>

          </select> </td>
</tr>

<tr><td colspan="6" bgcolor="#C1D799"><b>QUALIFICATION</b></td>
</tr>

<tr><td colspan="6">
    <div align="center">
      <table border="0">
        <tr>
          <td align="center" bgcolor="#C1D799"><b>Qualification</b></td>
          <td align="center" bgcolor="#C1D799"><b>Course</b></td>
          <td align="center" bgcolor="#C1D799"><b>Subject</b></td>
          <td align="center" bgcolor="#C1D799"><b>%Marks</b></td>
        </tr>
        <tr>
          <td>
      <select name=quali1><option><?print $erow[quali1]?></option>
<option>S.S.L.C
<option>Pre-Degree
<option>B.A
<option>MBA
<option>BCA
<option>B.B.A
<option>B.Com
<option>M.Com
<option>BDS
<option>BHM
<option>KGCE
<option>B.Sc
<option>B.Tech/B.E.
<option>LLB
<option>ITI
<option>Diploma
<option>ITC

            </select></td>
          <td><input type=text name=course1 size="28" value='<?print $erow[course1]?>'></td>
          <td><input type=text name=sub1 size="32" value='<?print $erow[sub1]?>'></td>
          <td><input type=text name=mark1 size="7" value='<?print $erow[mark1]?>'></td>
        </tr>
        <tr>
          <td>
      <select name=quali2 size="1"><option><?print $erow[quali2]?></option>
<option>S.S.L.C
<option>Pre-Degree
<option>B.A
<option>MBA
<option>BCA
<option>B.B.A
<option>B.Com
<option>M.Com
<option>BDS
<option>BHM
<option>KGCE
<option>B.Sc
<option>B.Tech/B.E.
<option>LLB
<option>ITI
<option>Diploma
<option>ITC

            </select></td>
          <td><input type=text name=course2 size="28" value='<?print $erow[course2]?>'></td>
          <td><input type=text name=sub2 size="32" value='<?print $erow[sub2]?>'></td>
          <td><input type=text name=mark2 size="7" value='<?print $erow[mark2]?>'></td>
        </tr>
        <tr>
          <td>
      <select name=quali3 size="1"><option><?print $erow[quali3]?></option>
<option>S.S.L.C
<option>Pre-Degree
<option>B.A
<option>MBA
<option>BCA
<option>B.B.A
<option>B.Com
<option>M.Com
<option>BDS
<option>BHM
<option>KGCE
<option>B.Sc
<option>B.Tech/B.E.
<option>LLB
<option>ITI
<option>Diploma
<option>ITC

            </select></td>
          <td><input type=text name=course3 size="28" value='<?print $erow[course3]?>'></td>
          <td><input type=text name=sub3 size="32" value='<?print $erow[sub3]?>'></td>
          <td><input type=text name=mark3 size="7" value='<?print $erow[mark3]?>'></td>
        </tr>
        <tr>
          <td>
      <select name=quali4 size="1"><option ><?print $erow[quali4]?></option>
<option>S.S.L.C
<option>Pre-Degree
<option>B.A
<option>MBA
<option>BCA
<option>B.B.A
<option>B.Com
<option>M.Com
<option>BDS
<option>BHM
<option>KGCE
<option>B.Sc
<option>B.Tech/B.E.
<option>LLB
<option>ITI
<option>Diploma
<option>ITC

            </select></td>
          <td><input type=text name=course4 size="28" value='<?print $erow[course4]?>'></td>
          <td><input type=text name=sub4 size="32" value='<?print $erow[sub4]?>'></td>
          <td><input type=text name=mark4 size="7" value='<?print $erow[mark4]?>'></td>
        </tr>
      </table>
    </div>
  </td>
</tr>

<tr><td colspan="6" bgcolor="#C1D799"><b>FAMILY DETAILS&nbsp;</b></td>
</tr>

<tr><td><font color='dark brown'> Marital Status</td><td colspan="5"> 
<select name='mstatus' size="1">
          <option><?print $erow[mstatus]?></option>
          <option>Single</option>
          <option>Married</option>
          <option>Window</option>
          <option>Widower</option>
          <option>Divorcee</option>
        </select>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br>
    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
</tr>
<?
 $dom=explode('-',$erow[domarg]);
?>
<tr><td>Date of Marriage</td><td colspan="5">dd<input type=text name='marrd' size=2 value='<?print $dom[2]?>'>
			      mm<input type=text name='marrm' size=2 value='<?print $dom[1]?>'>
			      yy<input type=text name='marry' size=4 value='<?print $dom[0]?>'></td>
</tr>

<tr><td> No of Children</td><td colspan="5"> Male <input type=text name='nom' size=2 value='<?print $erow[nom]?>'>
&nbsp;&nbsp;
        Female <input type=text name='nof' size=2 value='<?print $erow[nof]?>'>
  </td>
</tr>
<tr><td><font color='dark brown'>Wife/Husband's Name</td><td><input type=text name='wifename' size=40 onKeyDown=chkey(this) value='<?print $erow[wifename]?>'></td>

<?
 $dobw1=explode('-',$erow[dobw]);
?>

    <td>BirthDate</td><td colspan=2>dd<input type=text name='wd' size=2 value='<?print $dobw1[2]?>'>
			      mm<input type=text name='wm' size=2 value='<?print $dobw1[1]?>'>
			      yy<input type=text name='wy' size=4 value='<?print $dobw1[0]?>'></td></tr>

<?
 $dobcc1=explode('-',$erow[dobc1]);
?>

<tr><td><font color='dark brown'>Child Name 1</td><td><input type=text name='childname1' size=40 onKeyDown=chkey(this) value='<?print $erow[c1name]?>'></td>
    <td>BirthDate</td><td colspan=2>dd<input type=text name='cd1' size=2  value='<?print $dobcc1[2]?>'>
			      mm<input type=text name='cm1' size=2  value='<?print $dobcc1[1]?>'>
			      yy<input type=text name='cy1' size=4  value='<?print $dobcc1[0]?>'></td></tr>
<?
 $dobcc2=explode('-',$erow[dobc2]);
?>
<tr><td><font color='dark brown'>Child name 2</td><td><input type=text name='childname2' size=40 onKeyDown=chkey(this) value='<?print $erow[c2name]?>'></td>
    <td>BirthDate</td><td colspan=2>dd<input type=text name='cd2' size=2 value='<?print $dobcc2[2]?>'>
			      mm<input type=text name='cm2' size=2 value='<?print $dobcc2[1]?>'>
			      yy<input type=text name='cy2' size=4 value='<?print $dobcc2[0]?>'></td></tr>

<?
 $dobcc3=explode('-',$erow[dobc3]);
?>
<tr><td><font color='dark brown'>Child name 3</td><td><input type=text name='childname3' size=40 onKeyDown=chkey(this) value='<?print $erow[c3name]?>'></td>
    <td>BirthDate</td><td colspan=2>dd<input type=text name='cd3' size=2 value='<?print $dobcc3[2]?>'>
			      mm<input type=text name='cm3' size=2 value='<?print $dobcc3[1]?>'>
			      yy<input type=text name='cy3' size=4 value='<?print $dobcc3[0]?>'></td></tr>

<tr><td>Experience </td><td colspan=13><textarea name='remark' cols=90 rows=2><?print $erow[remark]?></textarea></td></tr>

<tr><td>Other Allowances </td><td colspan=13><textarea name='oallow' cols=90 rows=2><?print $erow[oallow]?></textarea></td></tr>
<tr> <td colspan=6>Bank a/c No. <input type=text name='bnkac' value='<?print $erow[bnkac]?>'></tr>

<tr><td colspan=10 align=center><input type=submit value='Update'> 
<input type=button value='Cancel' onClick=history.go(-1)></td></tr>
</table>
</form>
</center>
