ohctech_p8/select_employee_bp.php
Dushant Mali 899fb3e65a Upgrade 7 to 8
Upgrade 7 to 8
2024-11-02 18:03:13 +05:30

26 lines
679 B
PHP

<?php
include ('includes/config/config.php');
include ('includes/functions.php');
$query = "select checkup_date, sbp,dbp,heart_rate from checkup_form where checkup_date between '2019/04/1' and '2019/04/06' and emp_id='6' ";
if (! $result = @mysqli_query($conn,$query)) {
die(mysqli_error($conn));
}
$x = 0;
if (mysqli_num_rows($result) > 0) {
while ($row = mysqli_fetch_assoc($result)) {
$data[$x]['sbp'] = $row['sbp'];
$data[$x]['dbp'] = $row['dbp'];
$data[$x]['heart_rate'] = $row['heart_rate'];
$data[$x]['checkup_date']=date_format(date_create($row['checkup_date']),"d-M-Y");
$x++;
}
}
echo json_encode($data);
?>