/home/mip/public_html_/old-website/brokerxxx/report_applicant_hongkong2.php
<?
session_start();
require_once("func_all.php");

do_report_header2a("HongKong Format - ".get_applicantname($applicant_id));
$company = getdata_one("*","company",1,1);  	
$applicant = getdata_one("*","personal","applicant_id",$applicant_id);
$process = getdata_one("*","process","applicant_id",$applicant_id);
if(!strcasecmp(getname($applicant['country_id'],"country","country_id"),'Taiwan'))// if 1st country is equal to Taiwan in case insensitive way
   $applicantid_taiwan = $applicant['applicant_id1']; 
elseif(!strcasecmp(getname($applicant['country_id2'],"country","country_id"),'Taiwan'))// if 2nd country is equal to Taiwan in case insensitive way
   $applicantid_taiwan = $applicant['applicant_id2']; 
	 
$process = getdata_one("*","process","applicant_id",$applicant_id);   							

$dependents = getdata_one("*","dependents","applicant_id","$applicant_id");
$sql  ="select * from children where applicant_id =" . $applicant_id. " order by sex DESC";
$children = getdata($sql);
$children_num = count($children);


$sql  ="select * from siblings where applicant_id =" . $applicant_id. " AND sex='M' order by sex DESC";
$sibling_bro = getdata($sql);
$sibling_bro_num = count($sibling_bro);

$sql  ="select * from siblings where applicant_id =" . $applicant_id. " AND sex='F' order by sex DESC";
$sibling_sis = getdata($sql);

$sibling_sis_num = count($sibling_sis);

$hongkong = getdata_one("*","specialization_hk","applicant_id","$applicant_id");


$reference = getdata("Select * from reference where applicant_id ='" . $applicant_id . "' order by name ");
$reference_num = count($reference);

$employment = getdata("select *,DATE_FORMAT(from_date,'%b %Y') AS frm_date, IF(to_date,DATE_FORMAT(to_date,'%b %Y'),'PRESENT') as t_date from employment where applicant_id='$applicant_id' AND overseas<>1 order by from_date desc limit 3");
$num_emp = count($employment);

$employment1 = getdata("select *,DATE_FORMAT(from_date,'%b %Y') AS frm_date, IF(to_date,DATE_FORMAT(to_date,'%b %Y'),'PRESENT') as t_date from employment where applicant_id='$applicant_id' AND overseas=1 order by from_date desc limit 1");
$num_emp1 = count($employment1);

$questions_hk = getdata_one("*","questions_hk","applicant_id","$applicant_id");

	$educ_elem = getdata("select * from education where applicant_id=" .$applicant_id . " And education='Elementary'");
	$educ_high = getdata("select * from education where applicant_id=" .$applicant_id . " And education='Secondary'");
	$educ_college = getdata("select * from education where applicant_id=" .$applicant_id . " And education='College/University'");
	$educ_voc = getdata("select * from education where applicant_id=" .$applicant_id . " And education='Vocational'");
	$educ_voc_num  =count($educ_voc);
	$educ_post = getdata("select * from education where applicant_id=" .$applicant_id . " And education='Post Graduate'");
  $educ_post_num  =count($educ_post);
	$educ_lic = getdata("select * from education where applicant_id=" .$applicant_id . " And education='Licentiate'");
	$educ_lic_num  =count($educ_lic);
										?>

<tr><td height="100%" align=center valign="top">
<table align=center cellpadding='0' cellspacing='0' border=1 width=100% bordercolor="#000000">
<script language="JavaScript"><!--
				function cent(amount) {
          // returns the amount in the .99 format 
              amount -= 0;
              amount = (Math.round(amount*100))/100;
              return (amount == Math.floor(amount)) ? amount + '.00' : (  (amount*10 == Math.floor(amount*10)) ? amount + '0' : amount);
         }
</script>  
 <tr><td valign=top width=100%>
 <table border=1 align=center width="100%" cellpadding=3  bordercolor="black">
			<td>
			<table border=0 width=100%>
         <tr> 
			 		 <td valign="top">&nbsp;&nbsp;
					 <img src="<?=$img_dir?>jakelogoonly.jpg" align="center"><br>
					 <font color="green">
					 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
					 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
					 POEA License # 084-LB-082506-R
					 </font>					 						  					 
				   </td>
					 <td style="padding-left:50px;" valign="top">
					 <br><br>					  				
					 <font color="green"><b>
					<?=$company['agency_address']?><br>
					 Tel. no.:&nbsp;<?=$company['agency_tel']?><br>Fax: <?=$company['agency_fax']?><br>
					 Email: <?=$company['agency_email']?></font></b>					 					 					 
					 </font>
					 </td>
					 <td class="report" rowspan=3 align='center' width=200 height=200 valign='middle'>
												<?if ($applicant[picture]){print resize_pic1(200,200,$pic_dir1.$applicant[picture],"","","",1);}else{echo "RECENT<br>2 x 2<br>PHOTO";}?>
												</td>
				 </tr>
				 <tr>
				 <td colspan=2 align="center" class=report><font size=4><b><em>APPLICATION FORM</em></b></font>
				 </td>
				 </tr>
				 <tr>
				    <td width=100% colspan=2>
						<table border=0 width=100%>
				     <tr>
				 		 <td class=report>&nbsp;<b>Ref. No. : <?=$applicantid_taiwan?></b></td>
				 		 <td class=report>&nbsp;<b>Video No. :<?=$applicant["video"]?></b></td>				 
				 		 </tr>
						 </table>
						 </td>
					</tr>
			</table>
			</td>
			</tr>
			 
			
			 
			 <tr>
			 		 <td>					
							 <table width="100%" cellpadding=0 cellspacing=0 border=0>

										<tr bgcolor="#22A808">
												<td align="center" valign="middle"><b><font size=3 color="yellow"><em>P E R S O N A L   &nbsp;&nbsp;&nbsp;&nbsp;I N F O R M A T I O N</em></font></td>
										</tr>
												
							 </table>
						</td>
				</tr>
				<tr>
			 		 <td>							 
							 <table width="100%" cellpadding=1 cellspacing=1 border=0 bordercolor="maroon">
							 			<tr>
												<td><b>Employer's Name</td>
												<td>&nbsp;</td>
												<td class="line"><?=$applicant['lname']?></td>
												<td class="line" align="center"><?=$applicant['fname']?></td>
												<td class="line" align="center"><?=$applicant['mname']?></td>
												<td align="left" style="padding-left:25px;"><b>Nationality</td>
												<td class="line">:<?=$applicant["nationality"]?></td>
										</tr>
										<tr>
												<td >&nbsp;</td>
												<td align="center">&nbsp;</td>
												<td align="center">Family Name</td>
												<td align="center">First Name</td>
												<td align="center">Middle Name</td>												
												<td>&nbsp;</td>
												<td><b>&nbsp;</td>
										</tr>
										<tr>
												<td><b>Date of Birth</td>
												<td align="center">&nbsp;</td>
												<td class="line">:<?=dateformat($applicant['birthdate'])?></td>
												<td align="center"><b>Place of birth</b></td>
												<td class="line">:<?=$applicant['birthplace']?></td>
												<td style="padding-left:25px;"><b>Age</b></td>												
												<td class="line">:<?=get_age($applicant['birthdate'])?></td>
											
										</tr>
										
										<tr>
												<td><b>Province</td>
												<td align="center">&nbsp;</td>
												<td colspan=3>:
												<?=$applicant['perm_no']?>, <?=$applicant['perm_st']?>, 
												<?=$applicant['perm_city']?>, <?=$applicant['perm_prov']?> <?=$applicant['perm_zip']?>
												</td>												
												<td style="padding-left:25px;"><b>Religion</b></td>												
												<td class="line"><?=$applicant['religion']?></b></td>													
										</tr>
										<tr>
												<td><b>Contact No./s</td>
												<td align="center"><b>#1</b></td>
												<td class="line">:<?=$applicant['area_code1']?></td>
												<td align="center"><b>Area Code</b></td>
												<td class="line">:<?=$applicant['home_phone']?></td>
												<td style="padding-left:25px;"><b>Tel. No.</b></td>												
												<td class="line">:<?=get_age($applicant['birthdate'])?></td>
											
										</tr>
										<tr>
												<td>&nbsp;</td>
												<td align="center"><b>#2</b></td>
												<td class="line">:<?=$applicant['area_code2']?></td>
												<td align="center"><b>Area Code</b></td>
												<td class="line">:<?=$applicant['office_phone']?></td>
												<td style="padding-left:25px;"><b>Height</b></td>												
												<td class="line">:<?if($applicant['height2']=="ft"){
												      list($feet, $inch) = split("[.]", $applicant["height1"]);
																 
															$ft =	($feet)*100/3.28;
                  						$in = ($inch/12)*100/3.28;
															echo "<b>" . $converted_cm = round($ft+$in,2);	                  				
													}else{
													    echo $applicant["height1"];
													}
																
													 							
												?>&nbsp;cm</td>
											
										</tr>
										<tr>
												<td><b>Languages Spoken</td>
												<td align="center">&nbsp;</td>
												<td class="line" colspan=3>:<?=$applicant["languages"]?></td>
												<td style="padding-left:25px;"><b>Weight</b></td>												
												<td class="line">:<?=($applicant['weight2']=="lbs")?round(($applicant['weight1']/2.2),2):$applicant['weight1'];?>&nbsp;kgs</td>
											
										</tr>
										<tr>
												<td><b>Talents</td>
												<td align="center">&nbsp;</td>
												<td class="line" colspan=3>:<?=$applicant["special_skills"]?></td>
												<td align="center">&nbsp;</td>
												<td class="line">&nbsp;</td>
												
											
										</tr>
										<tr>
												<td><b>Passport No.</td>
												<td align="center">&nbsp;</td>
												<td class="line">:<?=$process["passport"]?></td>
												
												<td align="center"><b>Date of Issue</b></td>
												<td class="line">:<?=dateformat1($process["pp_date_issued"],"M d, Y")?></b></td>			
												<td style="padding-left:25px;"><b>Expiration</b></td>
																					
												<td class="line">:<?=dateformat1($process["pp_date_expires"]," M d, Y")?></td>
											
										</tr>
										<tr>
												<td colspan=3 bgcolor="#F9F8AE" align="center"><b>Marital Status(check w/c one applies to you):</b></td>
												
												<td>
												&nbsp;&nbsp;
												<?if($applicant['civil_status'] == 'Separated'){
												     print "<img src='img/maycheck.gif'>";
													}else{
														 print "<img src='img/walacheck.gif'>";
													}		 ?>
												&nbsp;Separated&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</b>
												</td>
												<td><?if($applicant['civil_status'] == 'Single parent(w/ kids but no marriage cert.)'){
												     print "<img src='img/maycheck.gif'>";
													}else{
														 print "<img src='img/walacheck.gif'>";
													}		 ?>&nbsp;Single parent(w/ kids but no marriage cert.) &nbsp;
												</td>
												
										    
										</tr>
										<td style="padding-left:0;" colspan=7 align='center'>&nbsp;&nbsp;&nbsp;&nbsp;
												<?if($applicant['civil_status'] == 'Single both status & passport'){
												     print "<img src='imgmaycheck.gif'>";
													}else{
														 print "<img src='img/walacheck.gif'>";
													}		 ?>
													Single both status & passport&nbsp;&nbsp;&nbsp;&nbsp;
													
													<?if($applicant['civil_status'] == 'Married but single passport'){
												     print "<img src='img/maycheck.gif'>";
													}else{
														 print "<img src='img/walacheck.gif'>";
													}		 ?>
													Married but single passport&nbsp;&nbsp;&nbsp;&nbsp;
													
													<?if($applicant['civil_status'] == 'Married but single passport'){
												     print "<img src='img/maycheck.gif'>";
													}else{
														 print "<img src='img/walacheck.gif'>";
													}		 ?>
													Married but single passport&nbsp;&nbsp;&nbsp;&nbsp;
													
													<?if($applicant['civil_status'] == 'Married both status and passport'){
												     print "<img src='img/maycheck.gif'>";
													}else{
														 print "<img src='img/walacheck.gif'>";
													}		 ?>
													Married both status and passport&nbsp;&nbsp;&nbsp;&nbsp;
													
													<?if($applicant['civil_status'] == 'Widow'){
												     print "<img src='img/maycheck.gif'>";
													}else{
														 print "<img src='img/walacheck.gif'>";
													}		 ?>
													Widow&nbsp;&nbsp;&nbsp;&nbsp;
												</td>
										<tr>
										</tr>
							</table>
					</td>
				</tr>
				<tr>
			 		 <td>					
							 <table width="100%" cellpadding=0 cellspacing=0 border=0>

										<tr bgcolor="#22A808">
												<td align="center" valign="middle"><b><font size=3 color="yellow"><em>F A M I L Y   &nbsp;&nbsp;&nbsp;&nbsp;B A C K G R O U N D</em></font></td>
										</tr>
												
							 </table>
						</td>
				</tr>
				<tr>
			 		 <td>							 
							 <table width="100%" cellpadding=0 cellspacing=0 border=0 bordercolor="maroon">
							 			<tr>
												<td><b>No. of Brothers</td>
												<td align="center">&nbsp;&nbsp;&nbsp;</td>
												
												<td class="line">:<?=$dependents["num_bro"]?></td>
												<td align="left"><b>Ages</b></td>
												<td colspan=7 class="line">:
												<?for($s=1;$s<=$sibling_bro_num;$s++){
											  echo $sibling_bro[$s]["c_age"];
												print "&nbsp;&nbsp;&nbsp;"; 
																																			
												}?>
												</td>
												
										</tr>
										
										<tr>
												<td><b>No. of sisters</td>
												<td align="center">&nbsp;</td>
												<td class="line">:<?=$dependents["num_sis"]?></td>
												<td align="left"><b>Ages</b></td>
												<td colspan=7 class="line">:
												<?for($s=1;$s<=$sibling_sis_num;$s++){
											  echo $sibling_sis[$s]["c_age"];
												print "&nbsp;&nbsp;&nbsp;"; 
																																			
												}?>
										</tr>
										
										<tr>
												<td><b>No. of Children</td>
												<td align="center">&nbsp;</td>
												<td class="line">:<?=$children_num?></td>
												<td align="left"><b>Ages</b></td>
												<td colspan=7 class="line">:
												<?for($s=1;$s<=$children_num;$s++){
											  echo $children[$s]["c_age"];
												print "&nbsp;&nbsp;&nbsp;"; 
																																			
												}?>
										</tr>
										<tr>
												<td><b>Husband's Name:</td>
												<td align="center">&nbsp;</td>
												<td class="line">:<?=$dependents["spouse_lname"]?>,&nbsp;<?=$dependents["spouse_fname"]?>&nbsp;<?=$dependents["spouse_mname"]?></td>
												<td align="left"><b>Occupation</b></td>
												<td colspan=7 class="line">:<?=$dependents["spouse_occup"]?></td>
												
										</tr>
										<tr>
												<td><b>You are the</td>
												<td align="center">&nbsp;</td>
												<td class="line">:<?=$dependents["num_family"]?></td>
												<td align="left"><b>in the Family</b></td>
												<td colspan=7>&nbsp;</td>
												
										</tr>
										
										
							</table>
					</td>
				</tr>
				
				<tr>
			 		 <td class=report>							 
							 <table width="100%" cellpadding=0 cellspacing=0 border=0 bordercolor="black" class=report>
							 			<tr>
												<td width=60% valign="top">
												   <table width="100%" cellpadding=0 cellspacing=0 border=0>
										         <tr bgcolor="#22A808">
												     <td align="center" valign="middle" colspan=3><b><font size=3 color="yellow"><em>E D U C A T I O N A L &nbsp;&nbsp;&nbsp;A T T A I N M E N T </em></font></td>
														 </tr>
														 <tr>
													   <td width=100>&nbsp;</td>
														 <td align="center" valign="middle" bgcolor='#F9F8AE'><b>Name of School/Year Graduated</td>
														 <td width=100>&nbsp;</td>
										         </tr>												
							             </table>	
													
							 			       <table width="100%" cellpadding=0 cellspacing=0 border=0 bordercolor="yellow">
							 						 		<tr>
															   <td width=100><b>Elementary:</td>												
															   <td class="line" colspan=5><?=$educ_elem[1]["school"]?></td>																								
															</tr>
															<tr>
																 <td align="right">&nbsp;</td>								
																 <td align="right" colspan=2 width=50%><b>From:</td>
																 <td class="line" width=20><?=$educ_elem[1]["from_date"]?></td>
																 <td align="right"><b>To:</td>
																 <td class="line" width=20 align="right"><?=$educ_elem[1]["to_date"]?></td>																								
															</tr>
															<tr>
															   <td width=100><b>High School:</td>												
															   <td class="line" colspan=5><?=$educ_high[1]["school"]?></td>																								
															</tr>
															<tr>
																 <td align="right">&nbsp;</td>								
																 <td align="right" colspan=2 width=50%><b>From:</td>
																 <td class="line" width=20><?=$educ_high[1]["from_date"]?></td>
																 <td align="right"><b>To:</td>
																 <td class="line" width=20 align="right"><?=$educ_high[1]["to_date"]?></td>																								
															</tr>
															<tr>
															   <td width=100><b>College/University:</td>												
															   <td class="line" colspan=5><?=$educ_college[1]["school"]?></td>																								
															</tr>
															<tr>
																 <td><b>Degree:</td> 
																 <td class="line"><?=$educ_college[1]["course"]?></td>								
																 <td align="right"><b>From:</td>
																 <td class="line" width=20><?=$educ_college[1]["from_date"]?></td>
																 <td align="right"><b>To:</td>
																 <td class="line" width=20 align="right"><?=$educ_college[1]["to_date"]?></td>																								
															</tr>
										       </table>
													 <br>
													 <table width="100%" cellpadding=0 cellspacing=0 border=0>
										         <tr bgcolor="#22A808">
												     <td align="center" valign="middle"><b><font size=3 color="yellow"><em>E M P L O Y M E N T &nbsp;&nbsp;&nbsp;&nbsp;H I S T O R Y </em></font></td>
										         </tr>												
							             </table>	
													
							 			       <table width="100%" cellpadding=2 cellspacing=2 border=0 bordercolor="yellow">
							 						 		<tr>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
															   <td align="center" width=40%  bgcolor="#F9F8AE"><b>Country Worked as DH</td>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
																 <td width=30% align="center"  bgcolor="#F9F8AE"><b>Years</td>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
																 <td width=30% align="center"  bgcolor="#F9F8AE">&nbsp;Months</td>												
															   <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>																							
															</tr>
															<?for($i=1;$i<=$num_emp;$i++){?>
															<tr>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
															   <td align="center" width=40% class="line"><?=($employment[$i]['country_id'])?getfield("name", "country", "country_id", $employment[$i]['country_id']):"&nbsp;"?></td>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
																 <td width=30% align="center" class="line"><?
																 
																 $years_to_months =$employment[$i]['total_years'];
																 
																 $total_years = $employment[$i]['total_years'];						   
																 $pos = strpos($total_years, ".");								
																 if($pos==TRUE){
				    										 			$divide = explode(".",$total_years);
					  										 			$years = $divide[0];
					  										 			if($years >1){
						   									 			   print $years . "&nbsp;yrs.&nbsp;";
																 			}elseif($years ==1){
						   									 			   print $years . "&nbsp;yr.&nbsp;";
																 			}else{
						   									 			   print "&nbsp;";
																 		  } 
					  										 			$month =  "."  . $divide[1];
					  										 			$month = round((float)$month * 12);
					  										 			if($month>1){
					     									 			    $month.="&nbsp;mos.";
																      }elseif($month==0){
						   									 			    $month ="";
																			}else{ 
																			    $month.="&nbsp;mo.";
																 			}   
																 }else{
				   											 			if($total_years > 1){
					     									 			    echo $total_years . "yrs.";
																 			}elseif($total_years == 1){
					     									 			    echo $total_years . "yr.";
					 											 		  }else{
					     									 			    echo "&nbsp;"; 
					 											 			}
					     
							 									 }
																 
																 
																 ?></td>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
																 <td width=30% align="center" class="line">&nbsp;<?=$month?>&nbsp;</td>												
															   <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>																							
															</tr>
															<?
															$month="";
															}?>
															<tr>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
															   <td colspan=5><b&nbsp;</td>																										
															   <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>																							
															</tr>
															<tr>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
															   <td colspan=5><p align="justify"><b>I certify that all my statement in this Applicantion from Employment is TRUE
																 		 							and Correct to the best of  MY knowledge and belief. I AGREE that,
																 									if gainfully employed, any misenterpretation(s). V), and(or) omission of facts
																									shall justify DISQUALIFICATION, DISMISSAL, OR REPATRIATION<br>from work.																								
															   <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>																							
															</tr>
																<tr>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
															   <td align="center" width=40% class="line">&nbsp;</td>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
																 <td width=30% align="center">&nbsp;</td>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
																 <td width=30% align="center">&nbsp;</td>												
															   <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>																							
															</tr>
															<tr>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
															   <td align="center" width=40%><b>Signature of Applicant</td>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
																 <td width=30% align="center">&nbsp;</td>
																 <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
																 <td width=30% align="center">&nbsp;</td>												
															   <td align="center">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>																							
															</tr>
										       </table>
																		
												</td>
												
												<td width=40% align="right" valign="top">
												<table class='report'>
													    <tr>
																	<td class='report' width=351 height=473 align='center' valign="top">
																	<?if ($applicant[picture_body]){print resize_pic1(351,473,$pic_dir1.$applicant[picture_body],"","","",1);}else{echo "PHOTO<br>WHOLE BODY";}?>
																	</td>
															</tr>
													 </table>
												</td>
												
										</tr>
										
										
							</table>
					</td>
				</tr>
				<tr><td valign=top width=100% class=report>
 <table border=0 align=center width="100%" cellpadding=3>
				
				<tr><td align='center'><b><u><font size=3>ANSWER SHEET</td></tr>				
				<tr>
											 		 <td width=100% class=report>
													 		 <table border=0 width=100%>	
															          <tr>
											 		 							    <td align="center" bgcolor="#22A808" colspan=4><b>
													 		 							<font color="yellow" size=3><em>SPECIALIZATION</em></font>
											 		 							    </td>
											 									</tr>														 				
																			  <tr>
											 		 							    <td colspan=4><b>
													 		 							Please rank the folowing duties according to your capabilities
											 		 							    </td>
											 									</tr>		
																		    <tr>
																			     <td class="line" align='center'><?=$hongkong["care_of_babies"]?>
																					 </td>
																					 <td>
																					 Care of Babies</td> 
																					 <td class="line" align='center'><?=$hongkong["tutoring"]?>
																					 </td>
																					 <td>
																					 Tutoring</td>									 		 								 		      																																			   		     										 
									 										 </tr>
																			  <tr>
																			     <td class="line" align='center'><?=$hongkong["care_of_young_children"]?>
																					 </td>
																					 <td>
																					 Care of Young Children</td> 
																					 <td class="line" align='center'><?=$hongkong["cooking"]?>
																					 </td><td>
																					 Cooking</td>									 		 								 		      																																			   		     										 
									 										 </tr>
																			
																			 <tr>
																			     <td class="line" align='center'><?=$hongkong["care_of_elderly_person"]?>
																					 </td>
																					 
																					 <td>
																					 Care of Elderly Person</td> 
																					 <td class="line" align='center'><?=$hongkong["care_of_pets"]?>
																					 </td>
																					 <td>
																					 Care of Pets</td>									 		 								 		      																																			   		     										 
									 										 </tr>
																			
																			 <tr>
																			     <td class="line" align='center'><?=$hongkong["care_of_disabled_person"]?>
																					 </td>
																					 <td>
																					 Care of Disabled Person</td> 
																					 <td class="line" align='center'><?=$hongkong["doing_gen_household"]?>
																					 </td>
																					 <td>
																					 Doing the General Household</td>									 		 								 		      																																			   		     										 
									 										 </tr>
																				
																		
																			 
															 </table>
													 </td>
							</tr>		 
							 <tr>
											 		 <td align="center" bgcolor="#22A808"><b>
													 <font color="yellow" size=3><em>WILLING & EXPERIENCE</em></font>
											 		 </td>
							</tr>						
							<tr>
			 		    <td  colspan=2 class=report>							 
							 <table cellpadding=3 cellspacing=2 border=0 width=100% bordercolor="red">
							 				<tr>
													<td colspan="2" width=></td>
													<td valign="bottom" align="center" colspan=2><b><u>Willing</td>
													<td rowspan=2></td>
													<td valign="bottom" align="center" colspan=2><b><u>Experienced</td>
											</tr>
											<tr>													
													<td valign="bottom" align="left" colspan=2><b>Part A</b></td>
												
													<td valign="bottom" align="center" width=60>Yes</td>																										
													<td valign="bottom" align="center" width=60>No</td>
													<td valign="bottom" align="center" width=60>Yes</td>																										
													<td valign="bottom" align="center" width=60>No</td>
											</tr>											
												
											<?
											$num_duties_hk = count($array_PartA_hk);
											for($i=1;$i<=$num_duties_hk;$i++){														 
												print "
																<tr>
																		<td valign='bottom' align='right' width='50'>$i.</td>
																		<td valign='bottom'>".$array_PartA_hk[$i]['duty']."</td>";
															
															print "<td valign='bottom' align='center'>&nbsp;";															
															print ($questions_hk[$array_PartA_hk[$i]['field'].'_willing']=='Yes')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
											  			print "</td>";
															print "<td valign='bottom' align='center'>&nbsp;";
															print ($questions_hk[$array_PartA_hk[$i]['field'].'_willing']=='No')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
											  			print "&nbsp;</td><td></td>";
															
															print "<td valign='bottom' align='center'>&nbsp;";
															print ($questions_hk[$array_PartA_hk[$i]['field'].'_exp']=='Yes')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
															print "&nbsp;</td>";
															print "<td valign='bottom' align='center'>&nbsp;";
															print ($questions_hk[$array_PartA_hk[$i]['field'].'_exp']=='No')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
															print "&nbsp;</td>";
														  $s =$i;
														  print "</tr>";																			
											 }
											 ?>
											 <tr>													
													<td valign="bottom" align="left" colspan=2><b>Part B</b></td>
												
													<td valign="bottom" align="center" width=60>&nbsp;</td>
													<td valign="bottom" align="center" width=60>&nbsp;</td>
													<td valign="bottom" align="center" width=60>&nbsp;</td>
													<td valign="bottom" align="center" width=60>&nbsp;</td>
																																							
													
											</tr>
											<?			
											 $num_duties_hkB = count($array_PartB_hk);
											 for($i=1;$i<=$num_duties_hkB;$i++){														 
												print "
																<tr>
																		<td valign='bottom' align='right' width='50'>";
																		print $i+$s .".";
																		print "</td>";
																		print "<td valign='bottom'>".$array_PartB_hk[$i]['duty']."</td>";
															
															print "<td valign='bottom' align='center'>&nbsp;";															
															print ($questions_hk[$array_PartB_hk[$i]['field'].'_willing']=='Yes')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
											  			print "</td>";
															print "<td valign='bottom' align='center'>&nbsp;";
															print ($questions_hk[$array_PartB_hk[$i]['field'].'_willing']=='No')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
											  			print "&nbsp;</td><td></td>";
															
															print "<td valign='bottom' align='center'>&nbsp;";
															print ($questions_hk[$array_PartB_hk[$i]['field'].'_exp']=='Yes')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
															print "&nbsp;</td>";
															print "<td valign='bottom' align='center'>&nbsp;";
															print ($questions_hk[$array_PartB_hk[$i]['field'].'_exp']=='No')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
															print "&nbsp;</td>
														 </tr>";																			
											 }	
											?>
											<tr>													
													<td valign="bottom" align="left" colspan=2><b>Part C</b></td>
												
													<td valign="bottom" align="center" width=60>&nbsp;</td>
													<td valign="bottom" align="center" width=60>&nbsp;</td>
													<td valign="bottom" align="center" width=60>&nbsp;</td>
													<td valign="bottom" align="center" width=60>&nbsp;</td>
																																							
													
											</tr>
											<?			
											 $num_duties_hkC = count($array_PartC_hk);
											 for($i=1;$i<=$num_duties_hkC;$i++){														 
												print "
																<tr>
																		<td valign='bottom' align='right' width='50'>";
																		print $i+$s .".";
																		print "</td>";
																		print "<td valign='bottom'>".$array_PartC_hk[$i]['duty']."</td>";
															
															print "<td valign='bottom' align='center'>&nbsp;";															
															print ($questions_hk[$array_PartC_hk[$i]['field'].'_willing']=='Yes')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
											  			print "</td>";
															print "<td valign='bottom' align='center'>&nbsp;";
															print ($questions_hk[$array_PartC_hk[$i]['field'].'_willing']=='No')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
											  			print "&nbsp;</td><td></td>";
															
															print "<td valign='bottom' align='center'>&nbsp;";
															print ($questions_hk[$array_PartC_hk[$i]['field'].'_exp']=='Yes')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
															print "&nbsp;</td>";
															print "<td valign='bottom' align='center'>&nbsp;";
															print ($questions_hk[$array_PartC_hk[$i]['field'].'_exp']=='No')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
															print "&nbsp;</td>
														 </tr>";																			
											 }	
											?>								
							 </table>
					 </td>
				</tr>
				<tr>
						<td align="center" bgcolor="#22A808" colspan=2 ><b>
						<font color="yellow" size=3><em>PERSONAL INFORMATION</em></font>
						</td>
			  </tr>		
				
				<tr>
			 		 <td class="report">							 
							 <table cellpadding=2 cellspacing=2 border=0>
							 				<tr>													
											<td valign="bottom" align="left" colspan=2>&nbsp;<b>Part D</b></td>																																															
										  </tr>		
											<tr>
													<td colspan="2"></td>
													<td valign="bottom" align="center" width=50><b>YES</td>
													<td width=10></td>
													<td valign="bottom" align="center"><b>NO</td>
											</tr>
											
											<?
											$num_PartD_hk = count($array_PartD_hk);
											for($i=1;$i<=$num_PartD_hk;$i++){														 
												print "
																<tr>
																		<td valign='top' align='right'>$i.</td>
																		<td valign='top'>".$array_PartD_hk[$i]['duty']."</td>";																														
															
															print "<td valign='bottom' align='center'>&nbsp;";
															print ($questions_hk[$array_PartD_hk[$i]['field']]=='Yes')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
															print "&nbsp;</td><td></td>";
															print "<td valign='bottom' align='center'>&nbsp;";
															print ($questions_hk[$array_PartD_hk[$i]['field']]=='No')? "<img src='img/maycheck.gif'>" : "<img src='img/walacheck.gif'>";
															print "&nbsp;</td>
														 </tr>";																			
											 }	
											?>				
							 </table>
					 </td>
				</tr>
				 <tr>													
						<td>
						<table border=0 width=100%>
						<tr>
						<td colspan=2>
						<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<b>I certify that all My statement in this Application for Employment is TRUE andC CORRECt  to the best of My knowledge and belief. I AGREE
						that if gainfully employed, any misrepresentation(s) and (or) omission of facts shall justify MY DISQUALIFICATION, DISMISSAL or
						REPATRIATION from work.
						</td>
						</tr>
						<tr height=50>
						<td class='line' width=20%>&nbsp;
						
						</td>
						<td width=80%>&nbsp;</td>
						</tr>
						<tr>
						<td align='center' width=20%>
						<b>Signature of Applicant</b>
						</td>
						<td width=80%>&nbsp;</td>
						</tr>
						</table>
						</td>																																																																																	
				</tr>	 		 					
 </table>						
 </td></tr>
 <?if($num_emp>0){?>
 <tr>
						<td align="center" colspan=2><b>
						<font size=3><em>WORKING HISTORY</em></font>
						</td>
 </tr>
 <?for($x=1;$x<=$num_emp;$x++){?>
 <tr>
						<td width=100%>		
							 <table border=0 width=100%>
							 <tr>
							 <td width=20>&nbsp;</td>
							 <td bgcolor="#22A808" align="center"><b><font size=3 color="yellow"><em><?=$x?>.&nbsp;DOMESTIC WORK EXPERIENCE (Please list the latest first)</em></font></b>&nbsp;</td>
							 <td width=20>&nbsp;</td>
							 </tr>
							 </table>	
						</td>							
						</tr>			
 <tr>
						<td align="center">
						<table border=0 width=100%>
				    <tr>
						   <td class="line" width=40% align="center"><?=$employment[$x]["company"]?></td>
							 <td width=20>&nbsp;</td>
							 <td class="line" width=30% align="center"><?=$employment[$x]["nationality"]?></td>
							 <td width=20>&nbsp;</td>
							 <td class="line" width=30%  align="center"><?=number_format($employment[$x]["salary"],2)?></td>												
						</tr>
						<tr>
						   <td align="center"><b>Name of Employer</b></td>
							 <td width=20>&nbsp;</td>
							 <td align="center"><b>Nationality</b></td>
							 <td width=20>&nbsp;</td>
							 <td  align="center"><b>Salary</b></td>												
						</tr>
						<tr>
						   <td class="line" class="report">
							     <table border=0>
									    <tr>
											<td align="right">From:</td>
											<td class="line" width=100 align="center"><?=dateformat1($employment[$x]["from_date"],"M d, Y")?></td>
											<td width=20>&nbsp;</td>
											<td align="right">To:</td>
											<td class="line" width=100 align="center"><?=dateformat1($employment[$x]["to_date"],"M Y")?></td>																						
											</tr>
											<tr>
											<td align="right">&nbsp;</td>
											<td width=100 align="center">(MM/DD/YY)</td>
											<td width=20>&nbsp;</td>
											<td align="right">&nbsp;</td>
											<td width=100 align="center">(MM/DD/YY)</td>																						
											</tr>
									 </table>
							 </td>
							 <td width=20>&nbsp;</td>
							 <td class="line" align="center"><?=getfield("name", "country", "country_id", $employment[$x]["country_id"])?></td>
							 <td width=20>&nbsp;</td>
							 <td class="line" align="center">
							 <table border=0 bordercolor=red cellpadding=0 cellspacing=0>
									    <tr>
											<td width=27%>Area Code:(</td>
											<td class="line" width=120 align="center"><?=($employment[$x]["area_code"])?$employment[$x]["area_code"]:"&nbsp;"?></td>
											<td width=50%>)&nbsp;</td>																															
											</tr>
										  <tr>
											<td align="right">&nbsp;</td>											
											<td width=100 align="center"><font color='#FFFFFF'>I</font></td>																						
											</tr>
									 </table>
									 <?=$employment1[1]["contact_no"]?>
							 </td>												
						</tr> 
						<tr>
						   <td align="center"><b>Date of Employment</b></td>
							 <td width=20>&nbsp;</td>
							 <td align="center"><b>Country</b></td>
							 <td width=20>&nbsp;</td>
							 <td align="center"><b>Contact No.</b></td>												
						</tr>		
						</td>
				</tr>
				<tr>
 <td style="padding-left:50px;" colspan=5><b><font size=2>Family Composition</font></b>
 </td>
 </tr>			
        <tr>
						   <td align="left">
							  <table border=0 width=100%>
									    <tr>
											<td align="right" width=100>No. of Adults:</td>
											<td class="line"><?=($employment[$x]["no_adults"])?$employment[$x]["no_adults"]:"&nbsp;"?></td>
											<td width=20>&nbsp;</td>
																															
											</tr>
											<tr>
											<td align="right">Age/s:</td>
											<td align="center" colspan=2 class="line">&nbsp;
											<?=($employment[$x]["age_adult1"])?$employment[$x]["age_adult1"]:""?>&nbsp;&nbsp;&nbsp;&nbsp;
											<?=($employment[$x]["age_adult2"])?$employment[$x]["age_adult2"]:""?>&nbsp;&nbsp;&nbsp;&nbsp;
											<?=($employment[$x]["age_adult2"])?$employment[$x]["age_adult3"]:""?>&nbsp;&nbsp;&nbsp;&nbsp;
											<?=($employment[$x]["age_adult2"])?$employment[$x]["age_adult4"]:""?>&nbsp;&nbsp;&nbsp;&nbsp;
											
											</td>
																														
											</tr>
									 </table>When you start working    
							 </td>
							 <td width=20>&nbsp;</td>
							 <td align="left">
							  <table border=0 width=100%>
									    <tr>
											<td align="right" width=100>No. of Elderly:</td>
											<td class="line">&nbsp;<?=($employment[$x]["no_elderly"])?$employment[$x]["no_elderly"]:"&nbsp;"?></td>
											<td width=20>&nbsp;</td>
											
																															
											</tr>
											<tr>
											<td align="right">Age/s:</td>
											<td align="center" colspan=2 class="line">&nbsp;
											<?=($employment[$x]["age_elderly1"])?$employment[$x]["age_elderly1"]:"&nbsp;"?>&nbsp;&nbsp;&nbsp;&nbsp;
											<?=($employment[$x]["age_elderly2"])?$employment[$x]["age_elderly2"]:"&nbsp;"?>&nbsp;&nbsp;&nbsp;&nbsp;
											<?=($employment[$x]["age_elderly3"])?$employment[$x]["age_elderly3"]:"&nbsp;"?>&nbsp;&nbsp;&nbsp;&nbsp;
											<?=($employment[$x]["age_elderly4"])?$employment[$x]["age_elderly4"]:"&nbsp;"?>&nbsp;&nbsp;&nbsp;&nbsp;
											</td>
																														
											</tr>
									 </table>When you start working    
							 </td>
							 <td width=20>&nbsp;</td>
							 <td align="left">
							  <table border=0 width=100%>
									    <tr>
											<td align="right" width=100>No. of Children:</td>
											<td class="line">&nbsp;<?=($employment[$x]["no_children"])?$employment[$x]["no_children"]:"&nbsp;"?></td>
											<td width=20>&nbsp;</td>
											
																															
											</tr>
											<tr>
											<td align="right">Age/s:</td>
											<td align="center" colspan=2 class="line">&nbsp;
											<?=($employment[$x]["age_children1"])?$employment[$x]["age_children1"]:"&nbsp;"?>&nbsp;&nbsp;&nbsp;&nbsp;
											<?=($employment[$x]["age_children2"])?$employment[$x]["age_children2"]:"&nbsp;"?>&nbsp;&nbsp;&nbsp;&nbsp;
											<?=($employment[$x]["age_children3"])?$employment[$x]["age_children3"]:"&nbsp;"?>&nbsp;&nbsp;&nbsp;&nbsp;
											<?=($employment[$x]["age_children4"])?$employment[$x]["age_children4"]:"&nbsp;"?>&nbsp;&nbsp;&nbsp;&nbsp;
											</td>
																														
											</tr>
									 </table>When you start working    
							 </td>												
						</tr>		
						</td>
 </tr>
 	<tr>
 <td style="padding-left:50px;" colspan=5><b><font size=2>REASON FOR LEAVING</font></b>
 </td>
 </tr>	
 <tr>
 <td colspan=5>
 <table border=0 bordercolor=green width=100%>
						<tr>
						<td>
					<? 
					
					
					switch($employment[$x]["reason_4Leaving"]){
					   
						 case 1:?>
						       <img src="img/maycheck.gif">
						&nbsp;<b>Finish Contract</b></td>
						<td><img src="img/walacheck.gif">&nbsp;<b>Migration to other Country</b></td>
						</tr>
						<tr>
						<td><img src="img/walacheck.gif">&nbsp;<b>Death</b></td>
						<td><img src="img/walacheck.gif">&nbsp;<b>Financial Difficulty</b></td>			
								  <? break;
						 case 2:?>
						<img src="img/walacheck.gif">            
						&nbsp;<b>Finish Contract</b></td>
						<td><img src="img/maycheck.gif">&nbsp;<b>Migration to other Country</b></td>
						</tr>
						<tr>
						<td><img src="img/walacheck.gif">&nbsp;<b>Death</b></td>
						<td><img src="img/walacheck.gif">&nbsp;<b>Financial Difficulty</b></td>
						<?  
								   break; 	
							
						 case 3: ?>
						       <img src="img/walacheck.gif">
						&nbsp;<b>Finish Contract</b></td>
						<td><img src="img/walacheck.gif">&nbsp;<b>Migration to other Country</b></td>
						</tr>
						<tr>
						<td><img src="img/maycheck.gif">&nbsp;<b>Death</b></td>
						<td><img src="img/walacheck.gif">&nbsp;<b>Financial Difficulty</b></td>
						<?	   break;
					   case 4: ?>
						      <img src="img/walacheck.gif">
						&nbsp;<b>Finish Contract</b></td>
						<td><img src="img/walacheck.gif">&nbsp;<b>Migration to other Country</b></td>
						</tr>
						<tr>
						<td><img src="img/walacheck.gif">&nbsp;<b>Death</b></td>
						<td><img src="img/maycheck.gif">&nbsp;<b>Financial Difficulty</b></td>
							<?	   break; 	
						 }	
						
						 ?>
						
									
						</tr>
						<tr>
						
						<td colspan=2><b>Other (Pls. Specify)</b></td>
						
						</tr>
						<tr>
						
						<td class="line">
						<?=$employment[$x]["reason_for_leaving"]?>
						</td>
						</tr>
						<tr>
						
						<td colspan=2>
						<b>
						<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I certify that all My statement in this Application for Employment is TRUE and CORRECT 
						to the best of MY knowledge and belief. I AGREE that, if gainfully employed, any misenterpretation(s), V), and (or)
						omission of facts shall justify DISQUALIFICATION, DISMISSAL or REPATRIATION from work.
						</td>
						</tr>
						<tr>
						<td><br>
								<table border=0 width=250>
								  <tr>
									<td class="line" align="center">&nbsp;</td>																		
									</tr>
									<tr>
									<td align="center"><b>Signature of Applicant</b></td>																		
									</tr>
								</table>
						</td>
						</tr>
						</table>
 </td>
 </tr>
 										 		 					
 </table>						
 </td></tr>
 <?}$first_selected="";
    $second_selected="";
		$third_seelcted="";
		$fourth_selected="";


}//end if $num_emp > 0		

 ?>			
 <tr>
						<td width=100%>		
							 <table border=0 width=100%>
							 <tr>
							 <td width=50>&nbsp;</td>
							 <td bgcolor="#22A808" align="center"><b><font size=3 color="yellow"><em>MESSAGE TO YOUR EMPLOYER</em></font></b>&nbsp;</td>
							 <td width=50>&nbsp;</td>
							 </tr>
							 </table>	
						</td>							
						</tr>		
 
        <tr>
						<td width=100% class=report>		
							 <table border=0 width=100%>
							 <tr height=25>
							    <td width=50>&nbsp;</td>
							 		<td>In your own hand writing</td>							 
							 </tr>
							 <tr height=25>
							 		 <td width=50>&nbsp;</td>
							 		 <td>(1)Explain briefly your duties and responsibilities daily from the time you wake up in the morning.</td>							 
							 </tr>
							  <tr height=25>
							 		 <td width=50>&nbsp;</td>
							 		 <td>(2)What are your selling points in order to convince the mployer to hire you?</td>							 
							 </tr>
							 </table>	
						</td>							
						</tr>		
         <tr>
						<td width=100% class=report>		
							 <table border=0 width=100%>
							 <tr height=25>
							    <td width=10%>&nbsp;</td>
							 		<td width=13%><em><b>Dear Employer,</b></em></td>
									<td width=67% class="line" colspan=2>&nbsp;</td>
									
									<td width=10%>&nbsp;</td>																 
							 </tr>
							 <?for($s=1;$s<=8;$s++){?>
							 <tr>
							    <td width=10%>&nbsp;</td>
							 		<td colspan=3 class="line" width=80%>&nbsp;</td>									
									<td width=10%>&nbsp;</td>																 
							 </tr>
							 <?}?>
							 <tr height=30>
							    <td width=10%>&nbsp;</td>
							 		<td width=13%>&nbsp;</td>
									<td width=67% class="line" colspan=2>&nbsp;</td>									
									<td width=10%>&nbsp;</td>																 
							 </tr>
							  <?for($s=1;$s<=7;$s++){?>
							 <tr>
							    <td width=10%>&nbsp;</td>
							 		<td colspan=3 class="line" width=80%>&nbsp;</td>									
									<td width=10%>&nbsp;</td>																 
							 </tr>
							 <?}?>
							 <tr height=25>
							    <td width=10%>&nbsp;</td>
							 		<td width=13%>&nbsp;</td>
									<td width=47%>&nbsp;</td>
									<td width=20% class="line">&nbsp;</td>									
									<td width=10%>&nbsp;</td>																 
							 </tr>
							  <tr height=25>
							    <td width=10%>&nbsp;</td>
							 		<td width=13%>&nbsp;</td>
									<td width=47%>&nbsp;</td>
									<td width=20% align="center"><b><em>Signature</em></b></td>									
									<td width=10%>&nbsp;</td>																 
							 </tr>
							 </table>	
						</td>							
						</tr>		
 <tr>
						<td width=100%>		
							 <table border=0 width=100%>
							 <tr>
							 <td width=50>&nbsp;</td>
							 <td bgcolor="#22A808" align="center"><b><font size=3 color="yellow"><em><?=$num_emp+1?>. NON-DOMESTIC WORK EXPERIENCE</em></font></b>&nbsp;</td>
							 <td width=50>&nbsp;</td>
							 </tr>
							 </table>	
						</td>							
						</tr>
						<tr>
						<td align="center">
						<table border=0 width=100%>
				    <tr>
						   <td class="line" width=40% align="center"><?=$employment1[1]["company"]?></td>
							 <td width=20>&nbsp;</td>
							 <td class="line" width=30% align="center"><?=$employment1[1]["nationality"]?></td>
							 <td width=20>&nbsp;</td>
							 <td class="line" width=30%  align="center"><?=number_format($employment1[1]["salary"],2)?></td>												
						</tr>
						<tr>
						   <td align="center"><b>Name of Employer</b></td>
							 <td width=20>&nbsp;</td>
							 <td align="center"><b>Nationality</b></td>
							 <td width=20>&nbsp;</td>
							 <td  align="center"><b>Salary</b></td>												
						</tr>
						<tr>
						   <td class="line" class="report">
							     <table border=0>
									    <tr>
											<td align="right">From:</td>
											<td class="line" width=100 align="center"><?=dateformat1($employment1[1]["from_date"],"M d, Y")?></td>
											<td width=20>&nbsp;</td>
											<td align="right">To:</td>
											<td class="line" width=100 align="center"><?=dateformat1($employment1[1]["to_date"],"M Y")?></td>																						
											</tr>
											<tr>
											<td align="right">&nbsp;</td>
											<td width=100 align="center">(MM/DD/YY)</td>
											<td width=20>&nbsp;</td>
											<td align="right">&nbsp;</td>
											<td width=100 align="center">(MM/DD/YY)</td>																						
											</tr>
									 </table>
							 </td>
							 <td width=20>&nbsp;</td>
							 <td class="line" align="center"><?=getfield("name", "country", "country_id", $employment1[1]["country_id"])?></td>
							 <td width=20>&nbsp;</td>
							 <td class="line" align="center">
							 <table border=0 bordercolor=red cellpadding=0 cellspacing=0>
									    <tr>
											<td width=27%>Area Code:(</td>
											<td class="line" width=120 align="center"><?=($employment1[1]["area_code"])?$employment1[1]["area_code"]:"&nbsp;"?></td>
											<td width=50%>)&nbsp;</td>																															
											</tr>
										  <tr>
											<td align="right">&nbsp;</td>											
											<td width=100 align="center"><font color='#FFFFFF'>I</font></td>																						
											</tr>
									 </table>
									 <?=$employment1[1]["contact_no"]?>
							 </td>												
						</tr> 
						<tr>
						   <td align="center"><b>Date of Employment</b></td>
							 <td width=20>&nbsp;</td>
							 <td align="center"><b>Country</b></td>
							 <td width=20>&nbsp;</td>
							 <td align="center"><b>Contact No.</b></td>												
						</tr>		
						</td>
				</tr>
				</table>
				</td>
				</tr>	
				<tr>
				  <td>
					     <table border=0 width=100%>
							 <tr>
							 <td width=20>&nbsp;</td>
							 <td width=20>&nbsp;</td>
							 <td width=200>
							 <b>Duties and Responsibilies</b></td>							 
							 <td>&nbsp;</td>
							 <td width=20>&nbsp;</td>
							 </tr>
							 <tr>
							 <td colspan=2>&nbsp;</td>
							 <td class="line" colspan=2>&nbsp;</td>							 
							 <td width=20>&nbsp;</td>
							 </tr>
							 <?for($e=1;$e<=3;$e++){?>
							 <tr>
							 <td>&nbsp;</td>
							 <td colspan=3 class="line">&nbsp;</td>							 
							 <td width=20>&nbsp;</td>
							 </tr>
							 <?}?>
							 </table>
					</td>
				</tr>	
				<tr>
 <td style="padding-left:50px;"><b><font size=2>REASON FOR LEAVING</font></b>
 </td>
 </tr>	
 <tr>
 <td>
 <table border=0 bordercolor=green width=100%>
						<tr>
						<td>
					<? 
					
					
					switch($employment1[1]["reason_4Leaving"]){
					   
						 case 1:?>
						       <img src="img/maycheck.gif">
						&nbsp;<b>Finish Contract</b></td>
						<td><img src="img/walacheck.gif">&nbsp;<b>Migration to other Country</b></td>
						</tr>
						<tr>
						<td><img src="img/walacheck.gif">&nbsp;<b>Death</b></td>
						<td><img src="img/walacheck.gif">&nbsp;<b>Financial Difficulty</b></td>			
								  <? break;
						 case 2:?>
						<img src="img/walacheck.gif">            
						&nbsp;<b>Finish Contract</b></td>
						<td><img src="img/maycheck.gif">&nbsp;<b>Migration to other Country</b></td>
						</tr>
						<tr>
						<td><img src="img/walacheck.gif">&nbsp;<b>Death</b></td>
						<td><img src="img/walacheck.gif">&nbsp;<b>Financial Difficulty</b></td>
						<?  
								   break; 	
							
						 case 3: ?>
						       <img src="img/walacheck.gif">
						&nbsp;<b>Finish Contract</b></td>
						<td><img src="img/walacheck.gif">&nbsp;<b>Migration to other Country</b></td>
						</tr>
						<tr>
						<td><img src="img/maycheck.gif">&nbsp;<b>Death</b></td>
						<td><img src="img/walacheck.gif">&nbsp;<b>Financial Difficulty</b></td>
						<?	   break;
					   case 4: ?>
						      <img src="img/walacheck.gif">
						&nbsp;<b>Finish Contract</b></td>
						<td><img src="img/walacheck.gif">&nbsp;<b>Migration to other Country</b></td>
						</tr>
						<tr>
						<td><img src="img/walacheck.gif">&nbsp;<b>Death</b></td>
						<td><img src="img/maycheck.gif">&nbsp;<b>Financial Difficulty</b></td>
							<?	   break; 	
						 }	
						
						 ?>
						
									
						</tr>
						<tr>
						
						<td colspan=2><b>Other (Pls. Specify)</b></td>
						
						</tr>
						<tr>
						
						<td class="line">
						<?=$employment1[1]["reason_for_leaving"]?>
						</td>
						</tr>
						<tr>
						
						<td colspan=2>
						<b>
						<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I certify that all My statement in this Application for Employment is TRUE and CORRECT 
						to the best of MY knowledge and belief. I AGREE that, if gainfully employed, any misenterpretation(s), V), and (or)
						omission of facts shall justify DISQUALIFICATION, DISMISSAL or REPATRIATION from work.
						</td>
						</tr>
						<tr>
						<td><br>
								<table border=0 width=250>
								  <tr>
									<td class="line" align="center">&nbsp;</td>																		
									</tr>
									<tr>
									<td align="center"><b>Signature of Applicant</b></td>																		
									</tr>
								</table>
						</td>
						</tr>
						</table>
 </td>
 </tr>
 										 		 					
 </table>						
 </td></tr>
 <?$first_selected="";
    $second_selected="";
		$third_seelcted="";
		$fourth_selected="";



 ?>			
				
				
 
<? 
do_report_footer();
?>