ok

Mini Shell

Direktori : /home2/selectio/www/saew.in/admin/print-form/
Upload File :
Current File : /home2/selectio/www/saew.in/admin/print-form/e-pehchan-card.php

<?php
ob_start();
session_start();
include"../config/config.php"; 

$id=$_POST['id'];
//$id=2;
//$statement = $pdo->prepare("SELECT tbl_user.*,(SELECT departement from tbl_departement WHERE id=tbl_user.department_id) as department_name,(SELECT desgination from tbl_desgination WHERE id=tbl_user.designation_id) as designation_name,tbl_branch.branch_name,tbl_branch.branch_location,tbl_branch.branch_address FROM `tbl_user` inner join tbl_branch on tbl_user.branch_id=tbl_branch.id where tbl_user.id ='$id'");
$statement = $pdo->prepare("SELECT tbl_user.*,(SELECT departement from tbl_departement WHERE id=tbl_user.department_id) as department_name,(SELECT desgination from tbl_desgination WHERE id=tbl_user.designation_id) as designation_name,tbl_branch.branch_name,tbl_branch.branch_location,tbl_branch.address as branch_address FROM `tbl_user` inner join tbl_branch on tbl_user.branch_id=tbl_branch.id where tbl_user.id ='$id'");
    $statement->execute();
    $emp_data = $statement->fetchAll(PDO::FETCH_ASSOC);
    $totalData = $statement->rowCount();
    //Single Quotation Lines
    $employees_style = "EMPLOYEES' STATE";
    $employers_code_no = "Employer's Code No:"; 
    $units_code_no = "Sub Unit's Code No:";
    
if($totalData){ 
 foreach($emp_data as $data){ 
     $family_member= json_decode($data['family_members'], true);
$content='

<table style="width: 100%;">
<tr>
	<td rowspan="2" style="width: 15%;"><img src="1.png" style="width:120px;"></td>
	<td><center><span class="title-form7">'.$employees_style.' INSURANCE CORPORATION</span></center></td>
</tr>
<tr>
	<td>
	<center><u style="font-weight: bold;font-family: Calibri;font-size:18px;">e-Pehchan Card / e-Pehchan அட்டை / ई-पहचान कार्ड</u></center>
	</td>
</tr>
</table>

	<br>
	    
	    <table style="width:100%;border: 1px solid black;">
	       <tr>
	            <td style="width: 50%;padding: 5px;font-family: Calibri;font-size:11px;">
	            Insured Person /<span class="tamil-font-size7">காப்பீடு செய்யப்பட்ட நபர் / बीमित व्यक्ति :</span></td>
	            <td>'.$data['emp_name'].'</td>
	       </tr>
	       <tr>
	            <td style="width: 50%;padding: 5px;font-family: Calibri;font-size:11px;">
	            Insurance No / <span class="tamil-font-size7">காப்பீடு எண் / बीमा संख्या :</span> </td>
	            <td>'.$data['insurance_no'].'</td>
	        </tr>
	        <tr>
	            <td style="width: 50%;padding: 5px;font-family: Calibri;font-size:11px;">
	            Date of Registration / <span class="tamil-font-size7">பதிவு செய்த தேதி / पंजीकरण की तिथि :</span> </td>
	            <td>'.date('d-m-Y', strtotime($data['insurance_date_of_registeration'])).'</td>
	        </tr>
	    </table>
	    
	    <center><u class="title7">YOUR REGISTRATION DETAILS</u></center>
	
	    <table style="width: 100%;">
	        <tr>
	            <td style="border: 1px solid black;padding: 5px;width: 20%;">Employee Name :</td>
	            <td style="border: 1px solid black;width: 30%;">'.$data['emp_name'].'</td>
	            <td style="border: 1px solid black;width: 20%;">Type of Disability</td>
	            <td style="border: 1px solid black;width: 30%;">None</td>
	        </tr>
	        <tr>
	            <td style="border: 1px solid black;padding: 5px;">Name of Father / Husband :</td>
	            <td style="border: 1px solid black;">'.$data['fname'].'</td>
	            <td style="border: 1px solid black;">Date of Birth :</td>
	            <td style="border: 1px solid black;">'.date('d-m-Y', strtotime($data['dob'])).'</td>
	        </tr>
	        <tr>
	            <td style="border: 1px solid black;padding: 5px;">Marital Status :</td>
	            <td style="border: 1px solid black;">'.$data['married_status'].'</td>
	            <td style="border: 1px solid black;">Gender :</td>
	            <td style="border: 1px solid black;">'.$data['gender'].'</td>
	        </tr>
	        <tr>
	            <td style="border: 1px solid black;padding: 5px;">Present Address :</td>
	            <td style="border: 1px solid black;">'.nl2br($data['address']).'</td>
	            <td style="border: 1px solid black;">Permanent Address :</td>
	            <td style="border: 1px solid black;">'.$data['permanentadress'].'</td>
	        </tr>
	        <tr>
	            <td style="border: 1px solid black;padding: 5px;">Dispensary / IMP for IP: </td>
	            <td style="border: 1px solid black;">None</td>
	            <td style="border: 1px solid black;">Dispensary / IMP for Family :</td>
	            <td style="border: 1px solid black;">None</td>
	        </tr>
	        <tr>
	            <td colspan="2" style="border: 1px solid black;padding: 5px;" class="title7"><center><u>Current Employer Details</u></center></td>
	            <td colspan="2" style="border: 1px solid black;padding: 5px;"class="title7"><center><u>First Employer Details</u></center></td>
	        </tr>
	        <tr>
	            <td style="border: 1px solid black;padding: 5px;">'.$employers_code_no.'</td>
	            <td style="border: 1px solid black;">'.$data['e_pehchan_emp_code_no'].'</td>
	            <td style="border: 1px solid black;">'.$employers_code_no.'</td>
	            <td style="border: 1px solid black;">None</td>
	        </tr>
	        <tr>
	            <td style="border: 1px solid black;padding: 5px;">'.$units_code_no.'</td>
	            <td style="border: 1px solid black;">'.$data['e_pehchan_sub_unit_code_no'].'</td>
	            <td style="border: 1px solid black;">'.$units_code_no.'</td>
	            <td style="border: 1px solid black;">None</td>
	        </tr>
	        <tr>
	            <td style="border: 1px solid black;padding: 5px;">Date of Appointment :</td>
	            <td style="border: 1px solid black;">None</td>
	            <td style="border: 1px solid black;">Date of Appointment :</td>
	            <td style="border: 1px solid black;">None</td>
	        </tr>
	        <tr>
	            <td style="border: 1px solid black;padding: 5px;">Name of Employer :</td>
	            <td style="border: 1px solid black;">M.SUNDARDAS & SONS</td>
	            <td style="border: 1px solid black;">Name of Employer :</td>
	            <td style="border: 1px solid black;">None</td>
	        </tr>
	        <tr>
	            <td style="border: 1px solid black;padding: 5px;">Address of Employer :</td>
	            <td style="border: 1px solid black;">'.$data['branch_address'].'</td>
	            <td style="border: 1px solid black;">Address of Employer :</td>
	            <td style="border: 1px solid black;">None</td>
	        </tr>
	    </table>
	    <br>
	    <span class="title7">Family Details:</span>
	    <table style="width: 100%;">
	        <tr>
	        <td style="border: 1px solid black;text-align: center;padding; 7px;">Name</td>
	        <td style="border: 1px solid black;text-align: center;padding; 7px;">Relationship with the Employee</td>
	        <td style="border: 1px solid black;text-align: center;padding; 7px;">Date of Birth</td>
	        <td style="border: 1px solid black;text-align: center;padding; 7px;">Whether Residing with Insured Person</td>
	        <td style="border: 1px solid black;text-align: center;padding; 7px;">State</td>
	        <td style="border: 1px solid black;text-align: center;padding; 7px;">District</td>
	        </tr>';
$n=1;	
foreach($family_member as $mem){ 
if (strlen($mem['family_member_address']) > 75)
  { $str = substr($mem['family_member_address'], 0, 75) . '...'; }else {$str=$mem['family_member_address']; }
$age = (date('Y') - date('Y',strtotime($mem['family_member_dob'])));
//'.date('d-m-Y', strtotime($mem['family_member_dob'])).'
$family_insured_person = "";
$family_member_dob = "";
if($mem['family_member_insured_person']=='1')
{ $family_insured_person = "YES"; } else { $family_insured_person = "NO"; }
if($mem['family_member_dob']=='' || $mem['family_member_dob']=='0000-00-00' || $mem['family_member_dob']=='1970-01-01')
{
 $family_member_dob = '';
}else
{
 $family_member_dob = date('d-m-Y', strtotime($mem['family_member_dob'])).' / ';
}
$content.='
	        <tr>
	            <td style="border: 1px solid black;padding: 3px;text-align: center;">'.$mem['family_member_name'].'</td>
	            <td style="border: 1px solid black;text-align: center;">'.$mem['family_member_relationship'].'</td>
	            <td style="border: 1px solid black;text-align: center;">'.$family_member_dob.''.$mem['family_member_age'].'</td>
	            <td style="border: 1px solid black;text-align: center;">'.$family_insured_person.'</td>
	            <td style="border: 1px solid black;text-align: center;">same</td>
	            <td style="border: 1px solid black;text-align: center;">same</td>
	        </tr>';
$n++;        
}	

	$content.='
	        </table>
	    <br>
	    <span class="title7">Nominee Details:</span>
	    <table style="width: 100%;">
	        <tr>
	        <td style="border: 1px solid black;text-align: center;">Name</td>
	        <td style="border: 1px solid black;text-align: center;">Relationship with IP</td>
	        <td style="border: 1px solid black;text-align: center;">Percentage</td>
	        <td style="border: 1px solid black;text-align: center;">Address of Nominee</td>
	        </tr>
	        <tr>
	            <td style="border: 1px solid black;padding: 3px;text-align: center;">'.$data['nominee_name'].'</td>
	            <td style="border: 1px solid black;text-align: center;">'.$data['nominee_relationship'].'</td>
	            <td style="border: 1px solid black;text-align: center;">'.$data['nominee_percentage'].'</td>
	            <td style="border: 1px solid black;text-align: center;">'.$data['nominee_address'].'</td>
	        </tr>
	    </table>
	    <br>
	    <span style=" font-family: Calibri;font-size:16px;font-weight: bold;">Documents Uploaded :</span>
	    <br>
	    <span style=" font-family: Calibri;font-size:11px;font-weight: bold;">'.$data['nominee_proof_type'].'</span>
	    <br>
	    <table style="width: 100%;">
	        <tr>
	            <td style="padding: 5px 0px; 1px 0px">Singnature / LTI of Registered Employee / IP :</td>
	        </tr>
	        <tr>
	           <td style="border: 1px solid black;width: 30%;height: 70px;"></td> 
	           <td style="width: 15%;"></td> 
	           <td rowspan="2" style="border: 1px solid black;height: 95px;vertical-align: top; padding: 1px;font-family: Calibri;
                    font-size: 10px;font-weight: bold;">Affix Your Family Photograph Here.(Attested and Stamped by Employer /ESIC Official)</td>
	        </tr>
	        <tr>
	            <td>Mobile Number : &nbsp &nbsp &nbsp '.$data['emp_mobile'].'</td>
	            <td></td>
	            <td></td>
	            <td></td>
	        </tr>
	    </table>
	    <span font-family: Calibri;font-size:14px;font-weight: bold;>Note : </span>
	    
	    <p class="calibri11_7">1. Please keep this printout for future reference and bring this along with your Photo ID for all your Claim Benefits and Medical Benefits.
	    <br>
	    2. Employer to please affix employee and his family photo here and attest with offcial stamp across.</p>
	    <br>
	    <p class="calibri11_7" style="text-align: end;">Signature  /  Stamp of Officer / Employer</p>
	    
	    <style>
                
                 .title-form7{
                    font-family: Calibri;
                    font-size:20px;font-weight: bold;
                }
                .tamil-font-size7{
                    font-family: Calibri;
                    font-size:9px;
                    font-weight: bold;
                }
                
                
                table{
                    border-collapse: collapse;
                }
                .calibri11_7
                {
                    font-family: Calibri;
                    font-size: 11px;font-weight: bold;
                }
                td{
                    font-family: Calibri;
                    font-size:11px;font-weight: bold;
                    padding: 2px;
                }
                .title7{
                font-family: Calibri;
                    font-size:14px;font-weight: bold;
                }
                
                
</style>';
}}else{ $content='<center>Empty</center>';}
echo $content;

Zerion Mini Shell 1.0