2 include_once("../../globals.php");
3 include_once("$srcdir/forms.inc");
4 include_once("$srcdir/encounter.inc");
5 include_once("$srcdir/patient.inc");
6 require_once("$srcdir/classes/Pharmacy.class.php");
11 <?php
html_header_show();?
>
13 <link rel
="stylesheet" href
="<?php echo $css_header;?>" type
="text/css">
16 <body
class="body_title">
19 $result = getPatientData($pid, "fname,lname,pid,pubpid,phone_home,pharmacy_id,DOB,DATE_FORMAT(DOB,'%Y%m%d') as DOB_YMD");
20 $provider_results = sqlQuery("select * from users where username='" . $_SESSION{"authUser"} . "'");
21 $age = getPatientAge($result["DOB_YMD"]);
23 $info = 'ID: ' . $result['pubpid'];
24 if ($result['DOB']) $info .= ', DOB: ' . $result['DOB'] . ', Age: ' . $age;
25 if ($result['phone_home']) $info .= ', Home: ' . $result['phone_home'];
27 if ($result['pharmacy_id']) {
28 $pharmacy = new Pharmacy($result['pharmacy_id']);
29 if ($pharmacy->get_phone()) $info .= ', Pharm: ' . $pharmacy->get_phone();
32 if (!empty($_GET["set_encounter"])) {
33 setencounter($_GET["set_encounter"]);
36 if(!empty($encounter)){
37 $subresult = getEncounterDateByEncounter($encounter);
38 $encounter_date = dateformat(strtotime($subresult['date']));
40 $encounter_date = dateformat(); //otherwise, set today's date
44 <table border
="0" cellpadding
="0" cellspacing
="0" width
="100%" height
="100%">
46 <td width
="33%" valign
="middle" nowrap
>
48 <span
class="title_bar_top"><?php
echo $result{"fname"} . " " . $result{"lname"};?
></span
>
50 <span style
="font-size:8pt;">(<?php
echo $info; ?
>)</span
>
52 <td width
="33%" align
="center" valign
="middle" nowrap
>
53 <span
class="title"><?php
echo xl('Logged in as') . ': ' . $provider_results{"fname"} . ' ' . $provider_results{"lname"}; ?
></span
>
55 <td width
="33%" align
="right" valign
="middle" nowrap
>
56 <span
class="title_bar_top"><?php
xl('Encounter','e', '', ' '); echo $encounter_date; ?
> </span
>