ESH/excel_emp_list.php
2024-10-23 18:28:06 +05:30

70 lines
1.5 KiB
PHP

<?php
header("Content-type:application/octet-stream");
header("Content-type: application/x-msdownload");
header("Content-Disposition: attachment; filename=excel_emp_list.xls");
header("Pragma: no-cache");
header("Expires: 0");
error_reporting(E_ALL & ~E_NOTICE & ~E_DEPRECATED);
?>
<?php
include('includes/config/config.php');
include('includes/functions.php')
//include('pop_up_top.php');
?>
<table border="1" width="100%">
<?php
$sql=base64_decode($filterkey);
$result = mysqli_query($conn,$sql);
// echo $result;
?><tr>
<th >EMP Code</th>
<th >Patient Name</th>
<th >Father Name</th>
<th >Designation</th>
<th >Department</th>
<th >AAdhar No</th>
<th >Gender</th>
<th >Blood Group</th>
<th >Primary phone</th>
<th >Is First Aider</th>
</tr><?php
$count=0;
error_reporting(E_ERROR | E_PARSE);
while ($rowOfEmployee = mysqli_fetch_array($result)) {
$count=$count+1;
?><tr>
<td><?php echo $rowOfEmployee['emp_code']?></td>
<td><?php echo $rowOfEmployee['patient_name']?></td>
<td><?php echo $rowOfEmployee['father_name']?></td>
<td><?php echo $rowOfEmployee['designation_name']?></td>
<td><?php echo $rowOfEmployee['dept_name']?></td>
<td><?php echo $rowOfEmployee['aadhar_no']?></td>
<td><?php echo $rowOfEmployee['gender']?></td>
<td><?php echo $rowOfEmployee['blood_group']?></td>
<td><?php echo $rowOfEmployee['primary_phone']?></td>
<td><?php echo $rowOfEmployee['is_first_aid']==1?'Yes':'No'?></td>
</tr><?php
}
?>
</table>