96 lines
2.3 KiB
PHP
96 lines
2.3 KiB
PHP
![]() |
<h2 style="padding-top: 20px; padding-bottom: 20px; background-color: black; color: white; text-align: center;font-family: Lucida Bright Demibold;">Health Index is on a scale of 0 to 7, 7 being the best, 0-1 being worst score - <?php echo $year ?> </h2>
|
||
|
|
||
|
<!DOCTYPE html>
|
||
|
<html lang="en">
|
||
|
<head>
|
||
|
<meta charset="UTF-8">
|
||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||
|
<title>Health Index Score</title>
|
||
|
<style>
|
||
|
.datatable {
|
||
|
border-collapse: collapse;
|
||
|
width: 100%;
|
||
|
font-size: 20px;
|
||
|
}
|
||
|
th, td {
|
||
|
padding: 8px;
|
||
|
text-align: center;
|
||
|
border: 1px solid #ddd;
|
||
|
}
|
||
|
tr:nth-child(even){background-color: #f2f2f2;}
|
||
|
.grand-total {
|
||
|
font-weight: bold;
|
||
|
}
|
||
|
</style>
|
||
|
</head>
|
||
|
<body>
|
||
|
<?php
|
||
|
$fisrtCount = count(array_unique($first_array));
|
||
|
$secondCount = count(array_unique($second_array));
|
||
|
$threeCount = count(array_unique($three_array));
|
||
|
$fourCount = count(array_unique($four_array));
|
||
|
$fiveCount = count(array_unique($five_array));
|
||
|
$sixCount = count(array_unique($six_array));
|
||
|
$sevenCount = count(array_unique($seven_array));
|
||
|
|
||
|
|
||
|
?>
|
||
|
<table style="font-family: Lucida Bright Demibold;" class="datatable" style="font-size: 20px;">
|
||
|
|
||
|
<thead>
|
||
|
<tr >
|
||
|
<th style="font-size: 20px;">Health index score (Workers)</th>
|
||
|
<th style="font-size: 20px;">Count of Total
|
||
|
score</th>
|
||
|
</tr>
|
||
|
</thead>
|
||
|
<tbody>
|
||
|
<tr style="background-color: #ff0000;">
|
||
|
<td>1</td>
|
||
|
<td>
|
||
|
<?php echo $fisrtCount ?>
|
||
|
</td>
|
||
|
</tr>
|
||
|
<tr style="background-color: #ff5733;" >
|
||
|
<td>2</td>
|
||
|
<td>
|
||
|
<?php echo $secondCount ?>
|
||
|
</td>
|
||
|
|
||
|
</tr>
|
||
|
<tr style="background-color: #f4b183;">
|
||
|
<td>3</td>
|
||
|
<td>
|
||
|
<?php echo $threeCount ?>
|
||
|
</td>
|
||
|
|
||
|
</tr>
|
||
|
<tr style="background-color: #9dc3e6;">
|
||
|
<td>4</td>
|
||
|
<td>
|
||
|
<?php echo $fourCount ?>
|
||
|
</td>
|
||
|
</tr>
|
||
|
<tr style="background-color: #92d050;">
|
||
|
<td>5</td>
|
||
|
<td>
|
||
|
<?php echo $fiveCount ?>
|
||
|
</td>
|
||
|
</tr>
|
||
|
<tr style="background-color: #00b050;">
|
||
|
<td>6-7</td>
|
||
|
<td>
|
||
|
<?php echo $sixCount ?>
|
||
|
</td>
|
||
|
|
||
|
</tr>
|
||
|
</tbody>
|
||
|
<tr>
|
||
|
<th style="font-size: 20px;" class="grand-total">Grand Total</th>
|
||
|
<td style="font-size: 20px;" class="grand-total"><?php echo $totalCount = ($fisrtCount+$secondCount+$threeCount+$fourCount+$fiveCount+$sixCount) ?></td>
|
||
|
</tr>
|
||
|
</table>
|
||
|
|
||
|
</body>
|
||
|
</html>
|