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 = 'encounter_top.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 = explode(" ", $record['form_date']);
27 $record['form_date'] = $dateparts[0];
30 if ($record['dob'] != "") {
31 $dateparts = explode(" ", $record['dob']);
32 $record['dob'] = $dateparts[0];
35 if ($record['sig_date'] != "") {
36 $dateparts = explode(" ", $record['sig_date']);
37 $record['sig_date'] = $dateparts[0];
42 <?php
html_header_show();?
>
44 <!-- supporting javascript code
-->
45 <script type
="text/javascript" src
="<?php echo $GLOBALS['assets_static_relative']; ?>/jquery-min-3-1-1/index.js"></script
>
46 <script type
="text/javascript" src
="<?php echo $GLOBALS['webroot'] ?>/library/textformat.js"></script
>
49 <link rel
="stylesheet" href
="<?php echo $css_header;?>" type
="text/css">
50 <link rel
="stylesheet" href
="../../forms/<?php echo $form_folder; ?>/style.css" type
="text/css">
54 <body
class="body_top">
56 Printed on
<?php
echo date("F d, Y", time()); ?
>
58 <form method
=post action
="">
59 <span
class="title"><?php
xl($form_name, 'e'); ?
></span
><br
>
61 <!-- container
for the main body of the form
-->
62 <div id
="print_form_container">
64 <div id
="print_general">
68 <input type
='text' size
='10' name
='form_date' id
='form_date'
69 value
='<?php echo stripslashes($record['form_date
']);?>'
70 title
='<?php xl('yyyy
-mm
-dd
', 'e
'); ?>'
74 Name
: <input id
="name" name
="name" type
="text" size
="50" maxlength
="250" value
="<?php echo stripslashes($record['name']);?>">
76 <input type
='text' size
='10' name
='dob' id
='dob'
77 value
='<?php echo stripslashes($record['dob
']);?>'
78 title
='<?php xl('yyyy
-mm
-dd Date of Birth
', 'e
'); ?>'
82 Phone
: <input name
="phone" id
="phone" type
="text" size
="15" maxlength
="15" value
="<?php echo stripslashes($record['phone']);?>">
85 Address
: <input name
="address" id
="address" type
="text" size
="80" maxlength
="250" value
="<?php echo stripslashes($record['address']);?>">
90 <div id
="print_bottom">
91 Use this space to express notes
<br
>
92 <textarea name
="notes" id
="notes" cols
="80" rows
="4"><?php
echo stripslashes($record['notes']);?
></textarea
>
94 <div style
="text-align:right;">
96 <input type
="radio" id
="sig" name
="sig" value
="y" <?php
if ($record["sig"] == 'y') {
100 <input type
="radio" id
="sig" name
="sig" value
="n" <?php
if ($record["sig"] == 'n') {
105 <input type
='text' size
='10' name
='sig_date' id
='sig_date'
106 value
='<?php echo stripslashes($record['sig_date
']);?>'
107 title
='<?php xl('yyyy
-mm
-dd
', 'e
'); ?>' />
111 </div
> <!-- end form_container
-->
117 <script language
="javascript">