%PDF- %PDF-
Direktori : /home/ugotscom/public_html/maputilities/ |
Current File : /home/ugotscom/public_html/maputilities/test1.php |
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <title>Final Output</title> <meta name="description" content="Bootstrap."> <link href="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css" rel="stylesheet"> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script> <link rel="stylesheet" href="http://cdn.datatables.net/1.10.2/css/jquery.dataTables.min.css"></style> <script type="text/javascript" src="http://cdn.datatables.net/1.10.2/js/jquery.dataTables.min.js"></script> <script type="text/javascript" src="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script> </head> <body style="margin:20px auto"> <div class="container"> <div class="row header" style="text-align:center;color:green"> <h3>Bootstrap</h3> </div> <?php $data = [ "requestID" => "4610", "timeofRequest" => "04052017134223", "developerName" =>"DL", "developerToken" =>"6m1u5m5f1w6a1e4x1r5w4k5mkush5232hsfllk", "seqNumber" =>"1", 'requestJSON' => [ "DeviceID"=>"ABCD123455", "APIVersionID"=> "V1.0", "ProviderID"=>"1008888888645939", "userID"=>"DL", "appToken"=> "56d16eeb1af647862d44musjgw870a4e1b", "UserType"=> "3", "PlatForm"=> "N", "AppType" => "N", "RequestEMRType"=>"1" ], ]; $json = json_encode($data); $curl = curl_init(); curl_setopt($curl, CURLOPT_URL, "http://34.80.119.140/musheer/api/Lab_tests/index"); curl_setopt($curl, CURLOPT_POSTFIELDS, $json); curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); $result = curl_exec($curl); curl_close($curl); $ar = json_decode($result,true); ?> <table id="myTable" class="table table-striped" > <thead> <tr> <th>Test Id</th> <th>Department</th> <th>Test Name</th> <th>Book</th> </tr> </thead> <tbody> <?php foreach ($ar['responseJSON']['data']['list'] as $ey) { ?> <tr> <td><?=$ey['MainTestID']?></td> <td><?=$ey['Dept']?></td> <td><?=$ey['MainTest']?></td> <td>Book Now</td> </tr> <?php } ?> </tbody> </table> </div> </body> <script> $(document).ready(function(){ $('#myTable').dataTable(); }); </script> </html>