stop reporting of a custom error (it is benign) to the php logfile
[openemr.git] / contrib / forms / example2 / report.php
blobf546ca65218104059e0c689827ca91d7136e6bec
1 <?php
2 include_once("../../globals.php");
3 include_once($GLOBALS["srcdir"]."/api.inc");
5 /** CHANGE THIS, the name of the function is significant and **
6 ** must be changed to match the folder name **/
7 function example_report( $pid, $encounter, $cols, $id) {
9 /** CHANGE THIS - name of the database table associated with this form **/
10 $table_name = "form_example";
12 $count = 0;
13 $data = formFetch($table_name, $id);
15 if ($data) {
17 print "<table><tr>";
19 foreach($data as $key => $value) {
20 if ($key == "id" || $key == "pid" || $key == "user" ||
21 $key == "groupname" || $key == "authorized" ||
22 $key == "activity" || $key == "date" ||
23 $value == "" || $value == "0000-00-00 00:00:00" ||
24 $value == "n")
26 // skip certain fields and blank data
27 continue;
30 $key=ucwords(str_replace("_"," ",$key));
31 print("<tr>\n");
32 print("<tr>\n");
33 print "<td><span class=bold>$key: </span><span class=text>$value</span></td>";
34 $count++;
35 if ($count == $cols) {
36 $count = 0;
37 print "</tr><tr>\n";
41 print "</tr></table>";
44 ?>