671b5376770fbf7cb041110900fe6d8f192f204f
[openemr.git] / interface / forms / note / print.php
blob671b5376770fbf7cb041110900fe6d8f192f204f
1 <?php
2 include_once("../../globals.php");
3 include_once("$srcdir/api.inc");
4 formHeader("Form: note");
5 $returnurl = $GLOBALS['concurrent_layout'] ? 'encounter_top.php' : 'patient_encounter.php';
6 $provider_results = sqlQuery("select fname, lname from users where username='" . $_SESSION{"authUser"} . "'");
8 /* name of this form */
9 $form_name = "note";
11 // get the record from the database
12 if ($_GET['id'] != "") $obj = formFetch("form_".$form_name, $_GET["id"]);
13 /* remove the time-of-day from the date fields */
14 if ($obj['date_of_signature'] != "") {
15 $dateparts = split(" ", $obj['date_of_signature']);
16 $obj['date_of_signature'] = $dateparts[0];
19 <html><head>
20 <?php html_header_show();?>
21 <link rel="stylesheet" href="<?php echo $css_header;?>" type="text/css">
23 <!-- supporting javascript code -->
24 <script type="text/javascript" src="<?php echo $GLOBALS['webroot'] ?>/library/js/jquery.js"></script>
26 </head>
27 <body class="body_top">
29 <form method=post action="">
30 <span class="title"><?php xl('Work/School Note','e'); ?></span><br></br>
31 <?php xl('Printed','e'); ?> <?php echo dateformat(); ?>
32 <br><br>
33 <select name="note_type">
34 <option value="WORK NOTE" <?php if ($obj['note_type']=="WORK NOTE") echo " SELECTED"; ?>><?php xl('WORK NOTE','e'); ?></option>
35 <option value="SCHOOL NOTE" <?php if ($obj['note_type']=="SCHOOL NOTE") echo " SELECTED"; ?>><?php xl('SCHOOL NOTE','e'); ?></option>
36 </select>
37 <br>
38 <b><?php xl('MESSAGE:','e'); ?></b>
39 <br>
40 <div style="border: 1px solid black; padding: 5px; margin: 5px;"><?php echo stripslashes($obj["message"]);?></div>
41 <br></br>
43 <table>
44 <tr><td>
45 <span class=text><?php xl('Doctor:','e'); ?> </span><input type=text name="doctor" value="<?php echo stripslashes($obj["doctor"]);?>">
46 </td><td>
47 <span class="text"><?php xl('Date','e'); ?></span>
48 <input type='text' size='10' name='date_of_signature' id='date_of_signature'
49 value='<?php echo $obj['date_of_signature']; ?>'
51 </td></tr>
52 </table>
54 </form>
56 </body>
58 <script language="javascript">
59 // jQuery stuff to make the page a little easier to use
61 $(document).ready(function(){
62 window.print();
63 window.close();
64 });
66 </script>
68 </html>