Highway to PSR2
[openemr.git] / contrib / forms / ped_pain / report.php
blob3135e6883c6ae1bb396503040a40127e33456644
1 <?php
2 //
4 include_once("../../globals.php");
5 include_once($GLOBALS["srcdir"]."/api.inc");
7 function ped_pain_report($pid, $encounter, $cols, $id)
9 $count = 0;
10 $data = formFetch("form_ped_pain", $id);
11 if ($data) :
12 print "<table span class=text><tr>";
13 foreach ($data as $key => $value) {
14 if ($key == "id" || $key == "pid" || $key == "user" || $key == "groupname" || $key == "authorized" || $key == "activity" || $key == "date" || $value == "" || $value == "0000-00-00 00:00:00") {
15 continue;
18 if ($value == "on") {
19 $value = "yes";
22 $key=ucwords(str_replace("_", " ", $key));
24 print "<td><span class=bold>$key: </span><span class=text>$value</span></td>";
26 $count++;
27 if ($count == $cols) {
28 $count = 0;
29 print "</tr><tr>\n";
33 print "</tr></table>";
34 endif;