本文整理汇总了PHP中formData函数的典型用法代码示例。如果您正苦于以下问题:PHP formData函数的具体用法?PHP formData怎么用?PHP formData使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了formData函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: myGetValue
function myGetValue($fldname)
{
$val = formData($fldname, 'G', true);
if ($val == 'undefined') {
$val = '';
}
return $val;
}
示例2: lab_results_messages
function lab_results_messages($set_pid, $rid, $provider_id = "")
{
if ($provider_id != "") {
$where = "AND id = '" . $provider_id . "'";
}
// Get all active users.
$rez = sqlStatement("select id, username from users where username != '' AND active = '1' {$where}");
for ($iter = 0; $row = sqlFetchArray($rez); $iter++) {
$result[$iter] = $row;
}
if (!empty($result)) {
foreach ($result as $user_detail) {
unset($thisauth);
// Make sure it is empty.
// Check user authorization. Only send the panding review message to authorised user.
// $thisauth = acl_check('patients', 'sign', $user_detail['username']);
// Route message to administrators if there is no provider match.
if ($provider_id == "") {
$thisauth = acl_check('admin', 'super', $user_detail['username']);
} else {
$thisauth = true;
}
if ($thisauth) {
// Send lab result message to the ordering provider when there is a new lab report.
$userauthorized = formData("userauthorized");
$pname = getPatientName($set_pid);
$link = "<a href='../../orders/orders_results.php?review=1&set_pid={$set_pid}'" . " onclick='return top.restoreSession()'>here</a>";
$note = "Patient {$pname}'s lab results have arrived. Please click {$link} to review them.<br/>";
$note_type = "Lab Results";
$message_status = "New";
// Add pnote.
$noteid = addPnote($set_pid, $note, $userauthorized, '1', $note_type, $user_detail['username']);
sqlQ("update pnotes set message_status='" . $message_status . "' where id = '{$noteid}'");
}
}
}
}
示例3: formData
<?php
// Copyright (C) 2009 Rod Roark <rod@sunsetsystems.com>
//
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation; either version 2
// of the License, or (at your option) any later version.
require_once "../../globals.php";
require_once "{$srcdir}/acl.inc";
require_once "{$srcdir}/options.inc.php";
require_once "{$srcdir}/patient.inc";
$CPR = 4;
// cells per row
// The form name is passed to us as a GET parameter.
$formname = formData('formname', 'G');
$tmp = sqlQuery("SELECT title FROM list_options WHERE " . "list_id = 'lbfnames' AND option_id = '{$formname}' LIMIT 1");
$formtitle = $tmp['title'];
$fres = sqlStatement("SELECT * FROM layout_options " . "WHERE form_id = '{$formname}' AND uor > 0 " . "ORDER BY group_name, seq");
?>
<html>
<head>
<?php
html_header_show();
?>
<style>
body, td {
font-family: Arial, Helvetica, sans-serif;
font-weight: normal;
font-size: 9pt;
示例4: formData
<?php
include_once "../globals.php";
require_once "{$srcdir}/formdata.inc.php";
$_SESSION["encounter"] = "";
// Fetching the password expiration date
if ($GLOBALS['password_expiration_days'] != 0) {
$is_expired = false;
$q = formData('authUser', 'P');
$result = sqlStatement("select pwd_expiration_date from users where username = '" . $q . "'");
$current_date = date("Y-m-d");
$pwd_expires_date = $current_date;
if ($row = sqlFetchArray($result)) {
$pwd_expires_date = $row['pwd_expiration_date'];
}
// Displaying the password expiration message (starting from 7 days before the password gets expired)
$pwd_alert_date = date("Y-m-d", strtotime($pwd_expires_date . "-7 days"));
if (strtotime($pwd_alert_date) != "" && strtotime($current_date) >= strtotime($pwd_alert_date) && (!isset($_SESSION['expiration_msg']) or $_SESSION['expiration_msg'] == 0)) {
$is_expired = true;
$_SESSION['expiration_msg'] = 1;
// only show the expired message once
}
}
if ($GLOBALS['athletic_team']) {
$frame1url = "../reports/players_report.php?embed=1";
} else {
if ($is_expired) {
$frame1url = "pwd_expires_alert.php";
//php file which display's password expiration message.
} elseif (isset($_GET['mode']) && $_GET['mode'] == "loadcalendar") {
$frame1url = "calendar/index.php?pid=" . $_GET['pid'];
示例5: sqlQuery
");
f.form_adreviewed.focus();
return false;
}
return true;
}
$(document).ready(function(){
$("#cancel").click(function() { window.close(); });
});
</script>
</head>
<body class="body_top">
<?php
if ($_POST['form_yesno']) {
sqlQuery("UPDATE patient_data SET completed_ad='" . formData('form_yesno', 'P', true) . "', ad_reviewed='" . formData('form_adreviewed', 'P', true) . "' where pid='{$pid}'");
// Close this window and refresh the calendar display.
echo "<html>\n<body>\n<script language='JavaScript'>\n";
echo " if (!opener.closed && opener.refreshme) opener.refreshme();\n";
echo " window.close();\n";
echo "</script>\n</body>\n</html>\n";
exit;
}
$sql = "select completed_ad, ad_reviewed from patient_data where pid='{$pid}'";
$myrow = sqlQuery($sql);
if ($myrow) {
$form_completedad = $myrow['completed_ad'];
$form_adreviewed = $myrow['ad_reviewed'];
}
?>
<span class="title"><?php
示例6: DOBandEncounter
function DOBandEncounter()
{
global $event_date, $info_msg;
// Save new DOB if it's there.
$patient_dob = trim($_POST['form_dob']);
if ($patient_dob && $_POST['form_pid']) {
sqlStatement("UPDATE patient_data SET DOB = '{$patient_dob}' WHERE " . "pid = '" . $_POST['form_pid'] . "'");
}
// Auto-create a new encounter if appropriate.
//
if ($GLOBALS['auto_create_new_encounters'] && $_POST['form_apptstatus'] == '@' && $event_date == date('Y-m-d')) {
$tmprow = sqlQuery("SELECT count(*) AS count FROM form_encounter WHERE " . "pid = '" . $_POST['form_pid'] . "' AND date = '{$event_date} 00:00:00'");
if ($tmprow['count'] == 0) {
$tmprow = sqlQuery("SELECT username, facility, facility_id FROM users WHERE id = '" . $_POST['form_provider'] . "'");
$username = $tmprow['username'];
$facility = $tmprow['facility'];
// $facility_id = $tmprow['facility_id'];
// use the session facility if it is set, otherwise the one from the provider.
$facility_id = $_SESSION['pc_facility'] ? $_SESSION['pc_facility'] : $tmprow['facility_id'];
$conn = $GLOBALS['adodb']['db'];
$encounter = $conn->GenID("sequences");
addForm($encounter, "New Patient Encounter", sqlInsert("INSERT INTO form_encounter SET " . "date = '{$event_date}', " . "onset_date = '{$event_date}', " . "reason = '" . formData("form_comments") . "', " . "facility = '{$facility}', " . "facility_id = '" . (int) $_POST['facility'] . "', " . "billing_facility = '" . (int) $_POST['billing_facility'] . "', " . "provider_id = '" . (int) $_POST['form_provider'] . "', " . "pid = '" . $_POST['form_pid'] . "', " . "encounter = '{$encounter}'"), "newpatient", $_POST['form_pid'], "1", "NOW()", $username);
$info_msg .= "New encounter {$encounter} was created. ";
}
}
}
示例7: array
{
$output = array();
$query = sqlStatement("SELECT " . implode(',', $fieldnames) . " FROM list_options where list_id = ? AND activity = 1 order by seq", array($list_id));
while ($ll = sqlFetchArray($query)) {
foreach ($fieldnames as $val) {
$output[$ll['option_id']][$val] = $ll[$val];
}
}
return $output;
}
$formid = formData('id', 'G') + 0;
// If Save or Transmit was clicked, save the info.
//
if ($_POST['bn_save'] || $_POST['bn_xmit']) {
$ppid = formData('form_lab_id') + 0;
$sets = "date_ordered = " . QuotedOrNull(formData('form_date_ordered')) . ", " . "provider_id = " . (formData('form_provider_id') + 0) . ", " . "lab_id = " . $ppid . ", " . "date_collected = " . QuotedOrNull(formData('form_date_collected')) . ", " . "order_priority = '" . formData('form_order_priority') . "', " . "order_status = '" . formData('form_order_status') . "', " . "clinical_hx = '" . formData('form_clinical_hx') . "', " . "patient_instructions = '" . formData('form_patient_instructions') . "', " . "patient_id = '" . $pid . "', " . "encounter_id = '" . $encounter . "', " . "history_order= '" . formData('form_history_order') . "'";
// If updating an existing form...
//
if ($formid) {
$query = "UPDATE procedure_order SET {$sets} " . "WHERE procedure_order_id = '{$formid}'";
sqlStatement($query);
} else {
$query = "INSERT INTO procedure_order SET {$sets}";
$formid = sqlInsert($query);
addForm($encounter, "Procedure Order", $formid, "procedure_order", $pid, $userauthorized);
}
// Remove any existing procedures and their answers for this order and
// replace them from the form.
sqlStatement("DELETE FROM procedure_answers WHERE procedure_order_id = ?", array($formid));
sqlStatement("DELETE FROM procedure_order_code WHERE procedure_order_id = ?", array($formid));
for ($i = 0; isset($_POST['form_proc_type'][$i]); ++$i) {
示例8: end_group
}
}
function end_group()
{
global $last_group;
if (strlen($last_group) > 0) {
end_row();
echo " </table>\n";
// No div for an empty group name.
if (strlen($last_group) > 1) {
echo "</div>\n";
}
}
}
$formname = formData('formname', 'G');
$formid = 0 + formData('id', 'G');
// Get title and number of history columns for this form.
$tmp = sqlQuery("SELECT title, option_value FROM list_options WHERE " . "list_id = 'lbfnames' AND option_id = '{$formname}'");
$formtitle = $tmp['title'];
$formhistory = 0 + $tmp['option_value'];
$newid = 0;
// If Save was clicked, save the info.
//
if ($_POST['bn_save']) {
$sets = "";
$fres = sqlStatement("SELECT * FROM layout_options " . "WHERE form_id = '{$formname}' AND uor > 0 AND field_id != '' AND " . "edit_options != 'H' " . "ORDER BY group_name, seq");
while ($frow = sqlFetchArray($fres)) {
$field_id = $frow['field_id'];
$value = get_layout_form_value($frow);
if ($formid) {
// existing form
示例9: batch_despatch
public static function batch_despatch($var, $func, $data_credentials)
{
global $pid;
if (UserService::valid($data_credentials)) {
require_once "../../library/invoice_summary.inc.php";
require_once "../../library/options.inc.php";
require_once "../../library/acl.inc";
require_once "../../library/patient.inc";
if ($func == 'ar_responsible_party') {
$patient_id = $pid;
$encounter_id = $var['encounter'];
$x['ar_responsible_party'] = ar_responsible_party($patient_id, $encounter_id);
return UserService::function_return_to_xml($x);
} elseif ($func == 'getInsuranceData') {
$type = $var['type'];
$given = $var['given'];
$x = getInsuranceData($pid, $type, $given);
return UserService::function_return_to_xml($x);
} elseif ($func == 'generate_select_list') {
$tag_name = $var['tag_name'];
$list_id = $var['list_id'];
$currvalue = $var['currvalue'];
$title = $var['title'];
$empty_name = $var['empty_name'];
$class = $var['class'];
$onchange = $var['onchange'];
$x['generate_select_list'] = generate_select_list($tag_name, $list_id, $currvalue, $title, $empty_name, $class, $onchange);
return UserService::function_return_to_xml($x);
} elseif ($func == 'xl_layout_label') {
$constant = $var['constant'];
$x['xl_layout_label'] = xl_layout_label($constant);
return UserService::function_return_to_xml($x);
} elseif ($func == 'generate_form_field') {
$frow = $var['frow'];
$currvalue = $var['currvalue'];
ob_start();
generate_form_field($frow, $currvalue);
$x['generate_form_field'] = ob_get_contents();
ob_end_clean();
return UserService::function_return_to_xml($x);
} elseif ($func == 'getInsuranceProviders') {
$i = $var['i'];
$provider = $var['provider'];
$insurancei = getInsuranceProviders();
$x = $insurancei;
return $x;
} elseif ($func == 'get_layout_form_value') {
$frow = $var['frow'];
$_POST = $var['post_array'];
$x['get_layout_form_value'] = get_layout_form_value($frow);
return UserService::function_return_to_xml($x);
} elseif ($func == 'updatePatientData') {
$patient_data = $var['patient_data'];
$create = $var['create'];
updatePatientData($pid, $patient_data, $create);
$x['ok'] = 'ok';
return UserService::function_return_to_xml($x);
} elseif ($func == 'updateEmployerData') {
$employer_data = $var['employer_data'];
$create = $var['create'];
updateEmployerData($pid, $employer_data, $create);
$x['ok'] = 'ok';
return UserService::function_return_to_xml($x);
} elseif ($func == 'newHistoryData') {
newHistoryData($pid);
$x['ok'] = 'ok';
return UserService::function_return_to_xml($x);
} elseif ($func == 'newInsuranceData') {
$_POST = $var[0];
foreach ($var as $key => $value) {
if ($key >= 3) {
$var[$key] = formData($value);
}
if ($key >= 1) {
$parameters[$key] = $var[$key];
}
}
$parameters[12] = fixDate($parameters[12]);
$parameters[27] = fixDate($parameters[27]);
call_user_func_array('newInsuranceData', $parameters);
$x['ok'] = 'ok';
return UserService::function_return_to_xml($x);
} elseif ($func == 'generate_layout_validation') {
$form_id = $var['form_id'];
ob_start();
generate_layout_validation($form_id);
$x = ob_get_clean();
return $x;
}
} else {
throw new SoapFault("Server", "credentials failed");
}
}
示例10: postcalendar_user_search
/**
* search events
*/
function postcalendar_user_search()
{
if (!(bool) PC_ACCESS_OVERVIEW) {
return _POSTCALENDARNOAUTH;
}
$tpl = new pcSmarty();
$k = formData("pc_keywords", "R");
//from library/formdata.inc.php
$k_andor = pnVarCleanFromInput('pc_keywords_andor');
$pc_category = pnVarCleanFromInput('pc_category');
$pc_facility = pnVarCleanFromInput('pc_facility');
$pc_topic = pnVarCleanFromInput('pc_topic');
$submit = pnVarCleanFromInput('submit');
$event_dur_hours = pnVarCleanFromInput('event_dur_hours');
$event_dur_minutes = pnVarCleanFromInput('event_dur_minutes');
$start = pnVarCleanFromInput('start');
$end = pnVarCleanFromInput('end');
// get list of categories for the user to choose from
$categories = postcalendar_userapi_getCategories();
$cat_options = '';
foreach ($categories as $category) {
$selected = "";
if ($pc_category == $category[id]) {
$selected = " SELECTED ";
}
//modified 8/09 by BM to allow translation if applicable
$cat_options .= "<option value=\"{$category['id']}\" {$selected}>" . xl_appt_category($category[name]) . "</option>";
}
$tpl->assign_by_ref('CATEGORY_OPTIONS', $cat_options);
$tpl->assign('event_dur_hours', $event_dur_hours);
$tpl->assign('event_dur_minutes', $event_dur_minutes);
// create default start and end dates for the search form
if (isset($start) && $start != "") {
$tpl->assign('DATE_START', $start);
} else {
$tpl->assign('DATE_START', date("m/d/Y"));
}
if (isset($end) && $end != "") {
$tpl->assign('DATE_END', $end);
} else {
$tpl->assign('DATE_END', date("m/d/Y", strtotime("+7 Days", time())));
}
// then override the setting if we have a value from the submitted form
$ProviderID = pnVarCleanFromInput("provider_id");
if (is_numeric($ProviderID)) {
$tpl->assign('ProviderID', $ProviderID);
} elseif ($ProviderID == "_ALL_") {
} else {
$tpl->assign('ProviderID', "");
}
$provinfo = getProviderInfo();
$tpl->assign('providers', $provinfo);
// build a list of provider-options for the select box on the input form -- JRM
$provider_options = "<option value='_ALL_' ";
if ($ProviderID == "_ALL_") {
$provider_options .= " SELECTED ";
}
$provider_options .= ">" . xl('All Providers') . "</option>";
foreach ($provinfo as $provider) {
$selected = "";
// if we don't have a ProviderID chosen, pick the first one from the
// pc_username Session variable
if ($ProviderID == "") {
// that variable stores the 'username' and not the numeric 'id'
if ($_SESSION['pc_username'][0] == $provider['username']) {
$selected = " SELECTED ";
}
} else {
if ($ProviderID == $provider['id']) {
$selected = " SELECTED ";
}
}
$provider_options .= "<option value=\"" . $provider['id'] . "\" " . $selected . ">";
$provider_options .= $provider['lname'] . ", " . $provider['fname'] . "</option>";
}
$tpl->assign_by_ref('PROVIDER_OPTIONS', $provider_options);
// build a list of facility options for the select box on the input form -- JRM
$facilities = getFacilities();
$fac_options = "<option value=''>" . xl('All Facilities') . "</option>";
foreach ($facilities as $facility) {
$selected = "";
if ($facility['id'] == $pc_facility) {
$selected = " SELECTED ";
}
$fac_options .= "<option value=\"" . $facility['id'] . "\" " . $selected . ">";
$fac_options .= $facility['name'] . "</option>";
}
$tpl->assign_by_ref('FACILITY_OPTIONS', $fac_options);
$PatientID = pnVarCleanFromInput("patient_id");
// limit the number of results returned by getPatientPID
// this helps to prevent the server from stalling on a request with
// no PID and thousands of PIDs in the database -- JRM
// the function getPatientPID($pid, $given, $orderby, $limit, $start) <-- defined in library/patient.inc
$plistlimit = 500;
if (is_numeric($PatientID)) {
$tpl->assign('PatientList', getPatientPID(array('pid' => $PatientID, 'limit' => $plistlimit)));
} else {
//.........这里部分代码省略.........
示例11: die
require_once "../../globals.php";
require_once "{$srcdir}/api.inc";
require_once "{$srcdir}/forms.inc";
require_once "{$srcdir}/formdata.inc.php";
if (!$encounter) {
// comes from globals.php
die(xlt("Internal error: we do not seem to be in an encounter!"));
}
if ($_POST["off_work_from"] == "0000-00-00" || $_POST["off_work_from"] == "") {
$_POST["is_unable_to_work"] = "0";
$_POST["off_work_to"] = "";
} else {
$_POST["is_unable_to_work"] = "1";
}
if ($_POST["hospitalization_date_from"] == "0000-00-00" || $_POST["hospitalization_date_from"] == "") {
$_POST["is_hospitalized"] = "0";
$_POST["hospitalization_date_to"] = "";
} else {
$_POST["is_hospitalized"] = "1";
}
$id = formData('id', 'G') + 0;
$sets = "pid = {$_SESSION["pid"]},\n groupname = '" . $_SESSION["authProvider"] . "',\n user = '" . $_SESSION["authUser"] . "',\n authorized = {$userauthorized}, activity=1, date = NOW(),\n employment_related = '" . formData("employment_related") . "',\n auto_accident = '" . formData("auto_accident") . "',\n accident_state = '" . formData("accident_state") . "',\n other_accident = '" . formData("other_accident") . "',\n outside_lab = '" . formData("outside_lab") . "',\n medicaid_referral_code = '" . formData("medicaid_referral_code") . "',\n epsdt_flag = '" . formData("epsdt_flag") . "',\n provider_id = '" . formData("provider_id") . "',\n provider_qualifier_code = '" . formData("provider_qualifier_code") . "',\n lab_amount = '" . formData("lab_amount") . "',\n is_unable_to_work = '" . formData("is_unable_to_work") . "',\n date_initial_treatment = '" . formData("date_initial_treatment") . "',\n off_work_from = '" . formData("off_work_from") . "',\n off_work_to = '" . formData("off_work_to") . "',\n is_hospitalized = '" . formData("is_hospitalized") . "',\n hospitalization_date_from = '" . formData("hospitalization_date_from") . "',\n hospitalization_date_to = '" . formData("hospitalization_date_to") . "',\n medicaid_resubmission_code = '" . formData("medicaid_resubmission_code") . "',\n medicaid_original_reference = '" . formData("medicaid_original_reference") . "',\n prior_auth_number = '" . formData("prior_auth_number") . "',\n replacement_claim = '" . formData("replacement_claim") . "',\n icn_resubmission_number = '" . formData("icn_resubmission_number") . "',\n box_14_date_qual = '" . formData("box_14_date_qual") . "',\n box_15_date_qual = '" . formData("box_15_date_qual") . "',\n comments = '" . formData("comments") . "'";
if (empty($id)) {
$newid = sqlInsert("INSERT INTO form_misc_billing_options SET {$sets}");
addForm($encounter, "Misc Billing Options", $newid, "misc_billing_options", $pid, $userauthorized);
} else {
sqlStatement("UPDATE form_misc_billing_options SET {$sets} WHERE id = {$id}");
}
formHeader("Redirecting....");
formJump();
formFooter();
示例12: AjaxDropDownCode
function AjaxDropDownCode()
{
if ($_REQUEST["ajax_mode"] == "set") {
$CountIndex = 1;
$StringForAjax = "<div id='AjaxContainerInsurance'><table width='552' border='1' cellspacing='0' cellpadding='0'>\n\t <tr class='text' bgcolor='#dddddd'>\n\t\t<td width='50'>" . htmlspecialchars(xl('Code'), ENT_QUOTES) . "</td>\n\t\t<td width='300'>" . htmlspecialchars(xl('Name'), ENT_QUOTES) . "</td>\n\t <td width='200'>" . htmlspecialchars(xl('Address'), ENT_QUOTES) . "</td>\n\t </tr>" . "<tr class='text' height='20' bgcolor='{$bgcolor}' id=\"tr_insurance_{$CountIndex}\"\n\t onkeydown=\"ProcessKeyForColoring(event,{$CountIndex});PlaceValues(event,' ','')\" onclick=\"PutTheValuesClick(' ','')\">\n\t\t\t<td colspan='3' align='center'><a id='anchor_insurance_code_{$CountIndex}' href='#'></a></td>\n\t </tr>";
$insurance_text_ajax = formData('insurance_text_ajax', '', true);
$res = sqlStatement("SELECT insurance_companies.id,name,city,state,country FROM insurance_companies\n\t\t\tleft join addresses on insurance_companies.id=addresses.foreign_id where name like '{$insurance_text_ajax}%' or insurance_companies.id like '{$insurance_text_ajax}%' ORDER BY name");
while ($row = sqlFetchArray($res)) {
if ($CountIndex % 2 == 1) {
$bgcolor = '#ddddff';
} else {
$bgcolor = '#ffdddd';
}
$CountIndex++;
$Id = $row['id'];
$Name = $row['name'];
$City = $row['city'];
$State = $row['state'];
$Country = $row['country'];
$Address = $City . ', ' . $State . ', ' . $Country;
$StringForAjax .= "<tr class='text' bgcolor='{$bgcolor}' id=\"tr_insurance_{$CountIndex}\"\n\t\tonkeydown='ProcessKeyForColoring(event,{$CountIndex});PlaceValues(event,\"" . htmlspecialchars($Id, ENT_QUOTES) . "\",\"" . htmlspecialchars($Name, ENT_QUOTES) . "\")'\n\t\t\t onclick='PutTheValuesClick(\"" . htmlspecialchars($Id, ENT_QUOTES) . "\",\"" . htmlspecialchars($Name, ENT_QUOTES) . "\")'>\n\t\t\t<td><a id='anchor_insurance_code_{$CountIndex}' href='#'>" . htmlspecialchars($Id) . "</a></td>\n\t\t\t<td><a href='#'>" . htmlspecialchars($Name) . "</a></td>\n\t\t <td><a href='#'>" . htmlspecialchars($Address) . "</a></td>\n</tr>";
}
$StringForAjax .= "</table></div>";
echo strlen($_REQUEST['insurance_text_ajax']) . '~`~`' . $StringForAjax;
die;
}
//===============================================================================
if ($_REQUEST["ajax_mode"] == "set_patient") {
//From 2 areas this ajax is called.So 2 pairs of functions are used.
//PlaceValues==>Used while -->KEY PRESS<-- over list.List vanishes and the clicked one gets listed in the parent page's text box.
//PutTheValuesClick==>Used while -->CLICK<-- over list.List vanishes and the clicked one gets listed in the parent page's text box.
//PlaceValuesDistribute==>Used while -->KEY PRESS<-- over list.List vanishes and the clicked one gets listed in the parent page's text box.
//PutTheValuesClickDistribute==>Used while -->CLICK<-- over list.List vanishes and the clicked one gets listed in the parent page's text box.
if (isset($_REQUEST['patient_code']) && $_REQUEST['patient_code'] != '') {
$patient_code = formData('patient_code', '', true);
if (isset($_REQUEST['submit_or_simple_type']) && $_REQUEST['submit_or_simple_type'] == 'Simple') {
$StringToAppend = "PutTheValuesClickPatient";
$StringToAppend2 = "PlaceValuesPatient";
} else {
$StringToAppend = "PutTheValuesClickDistribute";
$StringToAppend2 = "PlaceValuesDistribute";
}
$patient_code_complete = $_REQUEST['patient_code'];
//we need the spaces here
} elseif (isset($_REQUEST['insurance_text_ajax']) && $_REQUEST['insurance_text_ajax'] != '') {
$patient_code = formData('insurance_text_ajax', '', true);
$StringToAppend = "PutTheValuesClick";
$StringToAppend2 = "PlaceValues";
$patient_code_complete = $_REQUEST['insurance_text_ajax'];
//we need the spaces here
}
$CountIndex = 1;
$StringForAjax = "<div id='AjaxContainerPatient'><table width='452' border='1' cellspacing='0' cellpadding='0'>\n\t <tr class='text' bgcolor='#dddddd'>\n\t\t<td width='50'>" . htmlspecialchars(xl('Code'), ENT_QUOTES) . "</td>\n\t\t<td width='100'>" . htmlspecialchars(xl('Last Name'), ENT_QUOTES) . "</td>\n\t <td width='100'>" . htmlspecialchars(xl('First Name'), ENT_QUOTES) . "</td>\n\t <td width='100'>" . htmlspecialchars(xl('Middle Name'), ENT_QUOTES) . "</td>\n\t <td width='100'>" . htmlspecialchars(xl('Date of Birth'), ENT_QUOTES) . "</td>\n\t </tr>" . "<tr class='text' height='20' bgcolor='{$bgcolor}' id=\"tr_insurance_{$CountIndex}\"\n\t onkeydown=\"ProcessKeyForColoring(event,{$CountIndex});{$StringToAppend2}(event,' ','')\" onclick=\"{$StringToAppend}(' ','')\">\n\t\t\t<td colspan='5' align='center'><a id='anchor_insurance_code_{$CountIndex}' href='#'></a></td>\n\t </tr>\n\n\t ";
$res = sqlStatement("SELECT pid as id,fname,lname,mname,DOB FROM patient_data\n\t\t\t where fname like '{$patient_code}%' or lname like '{$patient_code}%' or mname like '{$patient_code}%' or \n\t\t\t CONCAT(lname,' ',fname,' ',mname) like '{$patient_code}%' or pid like '{$patient_code}%' ORDER BY lname");
while ($row = sqlFetchArray($res)) {
if ($CountIndex % 2 == 1) {
$bgcolor = '#ddddff';
} else {
$bgcolor = '#ffdddd';
}
$CountIndex++;
$Id = $row['id'];
$fname = $row['fname'];
$lname = $row['lname'];
$mname = $row['mname'];
$Name = $lname . ' ' . $fname . ' ' . $mname;
$DOB = oeFormatShortDate($row['DOB']);
$StringForAjax .= "<tr class='text' bgcolor='{$bgcolor}' id=\"tr_insurance_{$CountIndex}\"\n\t\t onkeydown='ProcessKeyForColoring(event,{$CountIndex});{$StringToAppend2}(event,\"" . htmlspecialchars($Id, ENT_QUOTES) . "\",\"" . htmlspecialchars($Name, ENT_QUOTES) . "\")' onclick=\"{$StringToAppend}('" . addslashes($Id) . "','" . htmlspecialchars(addslashes($Name), ENT_QUOTES) . "')\">\n\t\t\t<td><a id='anchor_insurance_code_{$CountIndex}' href='#' >" . htmlspecialchars($Id) . "</a></td>\n\t\t\t<td><a href='#'>" . htmlspecialchars($lname) . "</a></td>\n\t\t <td><a href='#'>" . htmlspecialchars($fname) . "</a></td>\n <td><a href='#'>" . htmlspecialchars($mname) . "</a></td>\n <td><a href='#'>" . htmlspecialchars($DOB) . "</a></td>\n </tr>";
}
$StringForAjax .= "</table></div>";
echo strlen($patient_code_complete) . '~`~`' . $StringForAjax;
die;
}
//===============================================================================
if ($_REQUEST["ajax_mode"] == "encounter") {
//PlaceValuesEncounter==>Used while -->KEY PRESS<-- over list.List vanishes and the clicked one gets listed in the parent page's text box.
//PutTheValuesClickEncounter==>Used while -->CLICK<-- over list.List vanishes and the clicked one gets listed in the parent page's text box.
if (isset($_REQUEST['encounter_patient_code'])) {
$patient_code = formData('encounter_patient_code', '', true);
$StringToAppend = "PutTheValuesClickEncounter";
$StringToAppend2 = "PlaceValuesEncounter";
}
$CountIndex = 1;
$StringForAjax = "<div id='AjaxContainerEncounter'><table width='202' border='1' cellspacing='0' cellpadding='0'>\n\t <tr class='text' bgcolor='#dddddd'>\n\t\t<td width='100'>" . htmlspecialchars(xl('Encounter'), ENT_QUOTES) . "</td>\n\t\t<td width='100'>" . htmlspecialchars(xl('Date'), ENT_QUOTES) . "</td>\n\t </tr>" . "<tr class='text' height='20' bgcolor='{$bgcolor}' id=\"tr_insurance_{$CountIndex}\"\n\t onkeydown=\"ProcessKeyForColoring(event,{$CountIndex});{$StringToAppend2}(event,' ','')\" onclick=\"{$StringToAppend}(' ','')\">\n\t\t\t<td colspan='2' align='center'><a id='anchor_insurance_code_{$CountIndex}' href='#'></a></td>\n\t </tr>\n\n\t ";
$res = sqlStatement("SELECT date,encounter FROM form_encounter\n\t\t\t where pid ='{$patient_code}' ORDER BY encounter");
while ($row = sqlFetchArray($res)) {
if ($CountIndex % 2 == 1) {
$bgcolor = '#ddddff';
} else {
$bgcolor = '#ffdddd';
}
$CountIndex++;
$Date = $row['date'];
$Date = split(' ', $Date);
$Date = oeFormatShortDate($Date[0]);
$Encounter = $row['encounter'];
$StringForAjax .= "<tr class='text' bgcolor='{$bgcolor}' id=\"tr_insurance_{$CountIndex}\"\n\t\t onkeydown=\"ProcessKeyForColoring(event,{$CountIndex});{$StringToAppend2}(event,'" . htmlspecialchars($Encounter, ENT_QUOTES) . "','" . htmlspecialchars($Date, ENT_QUOTES) . "')\" onclick=\"{$StringToAppend}('" . htmlspecialchars($Encounter, ENT_QUOTES) . "','" . htmlspecialchars($Date, ENT_QUOTES) . "')\">\n\t\t\t<td><a id='anchor_insurance_code_{$CountIndex}' href='#' >" . htmlspecialchars($Encounter) . "</a></td>\n\t\t\t<td><a href='#'>" . htmlspecialchars($Date) . "</a></td>\n </tr>";
}
$StringForAjax .= "</table></div>";
echo $StringForAjax;
//.........这里部分代码省略.........
示例13: htmlspecialchars
<td width="45" align="left" class="text"> <?php
echo htmlspecialchars(xl('Patient'), ENT_QUOTES) . ':';
?>
</td>
<td width="265"><input type="hidden" id="hidden_ajax_patient_close_value" value="<?php
echo $Message == '' ? htmlspecialchars($NameNew) : '';
?>
" />
<input name='patient_code' style="width:265px" id='patient_code' class="text" onKeyDown="PreventIt(event)"
value="<?php
echo $Message == '' ? htmlspecialchars($NameNew) : '';
?>
" autocomplete="off" /></td> <!--onKeyUp="ajaxFunction(event,'patient','edit_payment.php');" -->
<td width="55" colspan="2" style="padding-left:5px;" ><div class="text" name="patient_name" id="patient_name"
style="border:1px solid black; ; padding-left:5px; width:55px; height:17px;"><?php
echo $Message == '' ? htmlspecialchars(formData('hidden_patient_code')) : '';
?>
</div>
</td>
<td width="84" class="text"> <input type="radio" name="RadioPaid" onClick="SearchOnceMore()" <?php
echo $_REQUEST['RadioPaid'] == 'Non_Paid' || $_REQUEST['RadioPaid'] == '' ? 'checked' : '';
?>
value="Non_Paid" id="Non_Paid" /><?php
echo htmlspecialchars(xl('Non Paid'), ENT_QUOTES);
?>
</td>
<td width="168" class="text"><input type="radio" name="RadioPaid" onClick="SearchOnceMore()"
<?php
echo $_REQUEST['RadioPaid'] == 'Show_Primary_Complete' ? 'checked' : '';
?>
value="Show_Primary_Complete"
示例14: formData
require_once "{$srcdir}/forms.inc";
require_once "{$srcdir}/sql.inc";
require_once "{$srcdir}/encounter.inc";
require_once "{$srcdir}/acl.inc";
require_once "{$srcdir}/formatting.inc.php";
require_once "{$srcdir}/formdata.inc.php";
$conn = $GLOBALS['adodb']['db'];
$date = formData('form_date');
$onset_date = formData('form_onset_date');
$sensitivity = formData('form_sensitivity');
$pc_catid = formData('pc_catid');
$facility_id = formData('facility_id');
$billing_facility = formData('billing_facility');
$reason = formData('reason');
$mode = formData('mode');
$referral_source = formData('form_referral_source');
$facilityresult = sqlQuery("select name FROM facility WHERE id = {$facility_id}");
$facility = $facilityresult['name'];
if ($GLOBALS['concurrent_layout']) {
$normalurl = "patient_file/encounter/encounter_top.php";
} else {
$normalurl = "{$rootdir}/patient_file/encounter/patient_encounter.php";
}
$nexturl = $normalurl;
if ($mode == 'new') {
$provider_id = $userauthorized ? $_SESSION['authUserID'] : 0;
$encounter = $conn->GenID("sequences");
addForm($encounter, "New Patient Encounter", sqlInsert("INSERT INTO form_encounter SET " . "date = '{$date}', " . "onset_date = '{$onset_date}', " . "reason = '{$reason}', " . "facility = '{$facility}', " . "pc_catid = '{$pc_catid}', " . "facility_id = '{$facility_id}', " . "billing_facility = '{$billing_facility}', " . "sensitivity = '{$sensitivity}', " . "referral_source = '{$referral_source}', " . "pid = '{$pid}', " . "encounter = '{$encounter}', " . "provider_id = '{$provider_id}'"), "newpatient", $pid, $userauthorized, $date);
} else {
if ($mode == 'update') {
$id = $_POST["id"];
示例15: Validate
<tr>
<td><a href="#" onClick="javascript:return Validate();" class="css_button"><span><?php
echo htmlspecialchars(xl('Process ERA File'), ENT_QUOTES);
?>
</span></a></td>
</tr>
</table></td>
</tr>
<tr height="5">
<td align="left" ></td>
<td colspan="3" align="left" ></td>
</tr>
</table>
</td></tr>
</table>
</td>
</tr>
</table>
<input type="hidden" name="after_value" id="after_value" value="<?php
echo htmlspecialchars($alertmsg, ENT_QUOTES);
?>
"/>
<input type="hidden" name="hidden_type_code" id="hidden_type_code" value="<?php
echo formData('hidden_type_code');
?>
"/>
<input type='hidden' name='ajax_mode' id='ajax_mode' value='' />
</form>
</body>
</html>