2 include_once("../../globals.php");
3 include_once("$srcdir/sql.inc");
5 // This may be more appropriate to move to the library
7 require_once("{$GLOBALS['srcdir']}/sql.inc");
8 function getInsuranceCompanies($pid) {
9 $res = sqlStatement("SELECT * FROM insurance_data WHERE pid = '$pid' " .
10 "ORDER BY type ASC, date DESC");
12 for($iter = 0; $row = sqlFetchArray($res); $iter++
) {
13 if (strcmp($row['type'], $prevtype) == 0) continue;
14 $prevtype = $row['type'];
20 //the number of rows to display before resetting and starting a new column:
25 <?php
html_header_show();?
>
26 <link rel
="stylesheet" href
="<?php echo $css_header;?>" type
="text/css">
28 <body
class="body_bottom">
30 <table border
='0' cellspacing
='0' cellpadding
='0' height
='100%'>
37 <form method
='post' name
='copay_form' action
="diagnosis.php?mode=add&type=COPAY&text=copay"
38 target
='Diagnosis' onsubmit
='return top.restoreSession()'>
40 <dt
><span
class=title
><?php
xl('Copay','e'); ?
></span
></dt
>
43 <span
class='text'>$
</span
><input type
='entry' name
='code' value
='' size
='5' />
45 <input type
="SUBMIT" value
="<?php xl('Save','e'); ?>"><br
><br
>
47 <div
<?php
if ($GLOBALS['simplified_copay']) echo " style='display:none;'"; ?
>>
48 <input type
="RADIO" name
="payment_method" value
="cash" checked
><?php
xl('cash','e'); ?
>
49 <input type
="RADIO" name
="payment_method" value
="credit card"><?php
xl('credit','e'); ?
>
50 <input type
="RADIO" name
="payment_method" value
="check"><?php
xl('check','e'); ?
>
51 <input type
="RADIO" name
="payment_method" value
="other"><?php
xl('other','e'); ?
><br
><br
>
52 <input type
="RADIO" name
="payment_method" value
="insurance"><?php
xl('insurance','e'); ?
>
54 if ($ret=getInsuranceCompanies($pid)) {
56 echo "<select name=insurance_company>\n";
57 foreach($ret as $iter) {
58 $plan_name = trim($iter['plan_name']);
59 if ($plan_name != '') {
60 echo "<option value='"
62 ."'>".$plan_name ."\n";
70 <input type
="RADIO" name
="payment_method" value
="write off"><?php
xl('write off','e'); ?
>