3 * Sports Physical Form created by Jason Morrill: January 2009
6 include_once("../../globals.php");
7 include_once("$srcdir/api.inc");
9 /** CHANGE THIS - name of the database table associated with this form **/
10 $table_name = "form_example";
12 /** CHANGE THIS name to the name of your form **/
13 $form_name = "My Example Form";
15 /** CHANGE THIS to match the folder you created for this form **/
16 $form_folder = "example";
18 formHeader("Form: ".$form_name);
19 $returnurl = $GLOBALS['concurrent_layout'] ?
'encounter_top.php' : 'patient_encounter.php';
21 /* load the saved record */
22 $record = formFetch($table_name, $_GET["id"]);
24 /* remove the time-of-day from the date fields */
25 if ($record['form_date'] != "") {
26 $dateparts = split(" ", $record['form_date']);
27 $record['form_date'] = $dateparts[0];
29 if ($record['dob'] != "") {
30 $dateparts = split(" ", $record['dob']);
31 $record['dob'] = $dateparts[0];
33 if ($record['sig_date'] != "") {
34 $dateparts = split(" ", $record['sig_date']);
35 $record['sig_date'] = $dateparts[0];
40 <?php
html_header_show();?
>
42 <!-- supporting javascript code
-->
43 <script type
="text/javascript" src
="<?php echo $GLOBALS['webroot'] ?>/library/js/jquery.js"></script
>
44 <script type
="text/javascript" src
="<?php echo $GLOBALS['webroot'] ?>/library/textformat.js"></script
>
47 <link rel
="stylesheet" href
="<?php echo $css_header;?>" type
="text/css">
48 <link rel
="stylesheet" href
="../../forms/<?php echo $form_folder; ?>/style.css" type
="text/css">
52 <body
class="body_top">
54 Printed on
<?php
echo date("F d, Y", time()); ?
>
56 <form method
=post action
="">
57 <span
class="title"><?php
xl($form_name,'e'); ?
></span
><br
>
59 <!-- container
for the main body of the form
-->
60 <div id
="print_form_container">
62 <div id
="print_general">
66 <input type
='text' size
='10' name
='form_date' id
='form_date'
67 value
='<?php echo stripslashes($record['form_date
']);?>'
68 title
='<?php xl('yyyy
-mm
-dd
','e
'); ?>'
72 Name
: <input id
="name" name
="name" type
="text" size
="50" maxlength
="250" value
="<?php echo stripslashes($record['name']);?>">
74 <input type
='text' size
='10' name
='dob' id
='dob'
75 value
='<?php echo stripslashes($record['dob
']);?>'
76 title
='<?php xl('yyyy
-mm
-dd Date of Birth
','e
'); ?>'
80 Phone
: <input name
="phone" id
="phone" type
="text" size
="15" maxlength
="15" value
="<?php echo stripslashes($record['phone']);?>">
83 Address
: <input name
="address" id
="address" type
="text" size
="80" maxlength
="250" value
="<?php echo stripslashes($record['address']);?>">
88 <div id
="print_bottom">
89 Use this space to express notes
<br
>
90 <textarea name
="notes" id
="notes" cols
="80" rows
="4"><?php
echo stripslashes($record['notes']);?
></textarea
>
92 <div style
="text-align:right;">
94 <input type
="radio" id
="sig" name
="sig" value
="y" <?php
if ($record["sig"] == 'y') echo "CHECKED"; ?
>>Yes
96 <input type
="radio" id
="sig" name
="sig" value
="n" <?php
if ($record["sig"] == 'n') echo "CHECKED"; ?
>>No
99 <input type
='text' size
='10' name
='sig_date' id
='sig_date'
100 value
='<?php echo stripslashes($record['sig_date
']);?>'
101 title
='<?php xl('yyyy
-mm
-dd
','e
'); ?>' />
105 </div
> <!-- end form_container
-->
111 <script language
="javascript">