32 lines
907 B
PHP
32 lines
907 B
PHP
|
<?php
|
||
|
include('includes/config/config.php');
|
||
|
include ('includes/functions.php');
|
||
|
include ('log_entry.php');
|
||
|
error_log ( "Start Printing Request Attributes" );
|
||
|
$requestStr="";
|
||
|
foreach ( $_REQUEST as $key => $value ) {
|
||
|
$requestStr.=$key . " : " . $value . "\n";
|
||
|
error_log ( $key . " : " . $value . "<br />\r\n" );
|
||
|
}
|
||
|
error_log ( "End Printing Request Attributes" );
|
||
|
save_log($requestStr,'Report Master','SELECT','select_report_master.php');
|
||
|
$report_id = $_REQUEST['report_id'];
|
||
|
$query = "select * from report_master where report_id = '".$report_id."' ";
|
||
|
error_log("query: ".$query);
|
||
|
if (!$result = @mysqli_query($conn,$query)) {
|
||
|
exit(mysqli_error($conn));
|
||
|
}
|
||
|
$data = array();
|
||
|
if(mysqli_num_rows($result) > 0) {
|
||
|
while ($row = @mysqli_fetch_assoc($result)) {
|
||
|
$data = $row;
|
||
|
}
|
||
|
}
|
||
|
else
|
||
|
{
|
||
|
$data['status'] = 200;
|
||
|
$data['message'] = "Data not found!";
|
||
|
}
|
||
|
echo json_encode($data);
|
||
|
?>
|