本文整理汇总了PHP中fixDate函数的典型用法代码示例。如果您正苦于以下问题:PHP fixDate函数的具体用法?PHP fixDate怎么用?PHP fixDate使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了fixDate函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: loadTemplate
function loadTemplate($file, $rec = null)
{
global $scart;
$file = PATHTOTEMPLATESEDIT . "/" . $file;
$lines = file($file);
foreach ($lines as $line_num => $line_value) {
if ($line_num > 0) {
$working .= $line_value;
}
}
$read = $working;
preg_match_all('([[a-z|_]+])', $read, $matches);
if (is_array($matches)) {
foreach ($matches[0] as $key => $value) {
$findme = $value;
$rec_value = substr(trim($value, "]"), 1);
$replacewith = $rec[$rec_value];
if ($value == "[date]") {
$replacewith = fixDate($rec[$rec_value]);
}
if ($value == "[phone]") {
$replacewith = fixPhone($rec[$rec_value]);
}
if ($value == "[buyers_name]") {
$replacewith = stripslashes($_SESSION[SHOPPING_SESSION_ID]["field"]["fname"]) . " " . stripslashes($_SESSION[SHOPPING_SESSION_ID]["field"]["lname"]);
}
if ($value == "[company_name]") {
$replacewith = COMPANYNAME;
}
if ($value == "[company_phone]") {
$replacewith = fixPhone(CONTACTPHONE);
}
if ($value == "[company_email]") {
$replacewith = COMPANYEMAIL;
}
if ($value == "[admin_email]") {
$replacewith = SEND_SMTP_TO;
}
if ($value == "[invoice_amount]") {
$replacewith = "\$" . number_format($rec["amount"], 2);
}
if ($value == "[invoice_number]") {
$replacewith = $rec["inv_numb"];
}
if ($value == "[approval_code]") {
$replacewith = $rec["trans_numb"];
}
if ($value == "[last_four]") {
$replacewith = $rec["last_four"];
}
if ($value == "[giftcard_program]") {
$replacewith = GIFTCARD_PROGRAM;
}
$read = str_replace($findme, stripslashes($replacewith), $read);
}
}
return $read;
}
示例2: setInsurance
function setInsurance($pid, $ainsurance, $asubscriber, $seq)
{
$iwhich = $seq == '2' ? "secondary" : ($seq == '3' ? "tertiary" : "primary");
newInsuranceData($pid, $iwhich, $ainsurance["provider{$seq}"], $ainsurance["policy{$seq}"], $ainsurance["group{$seq}"], $ainsurance["name{$seq}"], $asubscriber["lname{$seq}"], $asubscriber["mname{$seq}"], $asubscriber["fname{$seq}"], $asubscriber["relationship{$seq}"], $asubscriber["ss{$seq}"], fixDate($asubscriber["dob{$seq}"]), $asubscriber["street{$seq}"], $asubscriber["zip{$seq}"], $asubscriber["city{$seq}"], $asubscriber["state{$seq}"], $asubscriber["country{$seq}"], $asubscriber["phone{$seq}"], $asubscriber["employer{$seq}"], $asubscriber["employer_street{$seq}"], $asubscriber["employer_city{$seq}"], $asubscriber["employer_zip{$seq}"], $asubscriber["employer_state{$seq}"], $asubscriber["employer_country{$seq}"], $ainsurance["copay{$seq}"], $asubscriber["sex{$seq}"]);
}
示例3: isset
echo " \n";
echo " </td>\n";
echo " </tr>\n";
$grand_total_charges += $docrow['charges'];
$grand_total_copays += $docrow['copays'];
$grand_total_encounters += $docrow['encounters'];
$docrow['charges'] = 0;
$docrow['copays'] = 0;
$docrow['encounters'] = 0;
}
$form_facility = isset($_POST['form_facility']) ? $_POST['form_facility'] : '';
$form_from_date = fixDate($_POST['form_from_date'], date('Y-m-d'));
$form_to_date = fixDate($_POST['form_to_date'], date('Y-m-d'));
if ($_POST['form_refresh']) {
$form_from_date = fixDate($_POST['form_from_date'], date('Y-m-d'));
$form_to_date = fixDate($_POST['form_to_date'], "");
// MySQL doesn't grok full outer joins so we do it the hard way.
//
$query = "( " . "SELECT " . "e.pc_eventDate, e.pc_startTime, " . "fe.encounter, fe.date AS encdate, " . "f.authorized, " . "p.fname, p.lname, p.pid, p.pubpid, " . "CONCAT( u.lname, ', ', u.fname ) AS docname " . "FROM openemr_postcalendar_events AS e " . "LEFT OUTER JOIN form_encounter AS fe " . "ON fe.date = e.pc_eventDate AND fe.pid = e.pc_pid " . "LEFT OUTER JOIN forms AS f ON f.pid = fe.pid AND f.encounter = fe.encounter AND f.formdir = 'newpatient' " . "LEFT OUTER JOIN patient_data AS p ON p.pid = e.pc_pid " . "LEFT OUTER JOIN users AS u ON u.id = fe.provider_id WHERE ";
if ($form_to_date) {
$query .= "e.pc_eventDate >= '{$form_from_date}' AND e.pc_eventDate <= '{$form_to_date}' ";
} else {
$query .= "e.pc_eventDate = '{$form_from_date}' ";
}
if ($form_facility !== '') {
$query .= "AND e.pc_facility = '{$form_facility}' ";
}
// $query .= "AND ( e.pc_catid = 5 OR e.pc_catid = 9 OR e.pc_catid = 10 ) " .
$query .= "AND e.pc_pid != '' AND e.pc_apptstatus != '?' " . ") UNION ( " . "SELECT " . "e.pc_eventDate, e.pc_startTime, " . "fe.encounter, fe.date AS encdate, " . "f.authorized, " . "p.fname, p.lname, p.pid, p.pubpid, " . "CONCAT( u.lname, ', ', u.fname ) AS docname " . "FROM form_encounter AS fe " . "LEFT OUTER JOIN openemr_postcalendar_events AS e " . "ON fe.date = e.pc_eventDate AND fe.pid = e.pc_pid AND " . "e.pc_pid != '' AND e.pc_apptstatus != '?' " . "LEFT OUTER JOIN forms AS f ON f.pid = fe.pid AND f.encounter = fe.encounter AND f.formdir = 'newpatient' " . "LEFT OUTER JOIN patient_data AS p ON p.pid = fe.pid " . "LEFT OUTER JOIN users AS u ON u.id = fe.provider_id WHERE ";
if ($form_to_date) {
// $query .= "LEFT(fe.date, 10) >= '$form_from_date' AND LEFT(fe.date, 10) <= '$form_to_date' ";
示例4: fixDate
// Copyright (C) 2008 Rod Roark <rod@sunsetsystems.com>
// Copyright (C) 2010 Tomasz Wyderka <wyderkat@cofoh.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.
// This report lists non reported patient diagnoses for a given date range.
require_once "../globals.php";
require_once "{$srcdir}/patient.inc";
require_once "../../custom/code_types.inc.php";
if (isset($_POST['form_from_date'])) {
$from_date = $_POST['form_from_date'] !== "" ? fixDate($_POST['form_from_date'], date('Y-m-d')) : 0;
}
if (isset($_POST['form_to_date'])) {
$to_date = $_POST['form_to_date'] !== "" ? fixDate($_POST['form_to_date'], date('Y-m-d')) : 0;
}
//
$form_code = isset($_POST['form_code']) ? $_POST['form_code'] : array();
//
if (empty($form_code)) {
$query_codes = '';
} else {
$query_codes = 'c.id in (';
foreach ($form_code as $code) {
$query_codes .= $code . ",";
}
$query_codes = substr($query_codes, 0, -1);
$query_codes .= ') and ';
}
//
示例5: add_date
$fake_register_globals = false;
require_once "../globals.php";
require_once "{$srcdir}/patient.inc";
require_once "{$srcdir}/options.inc.php";
require_once "../drugs/drugs.inc.php";
require_once "{$srcdir}/formatting.inc.php";
function add_date($givendate, $day = 0, $mth = 0, $yr = 0)
{
$cd = strtotime($givendate);
$newdate = date('Y-m-d', mktime(date('h', $cd), date('i', $cd), date('s', $cd), date('m', $cd) + $mth, date('d', $cd) + $day, date('Y', $cd) + $yr));
return $newdate;
}
$type = $_POST["type"];
$facility = isset($_POST['facility']) ? $_POST['facility'] : '';
$sql_date_from = fixDate($_POST['date_from'], date('Y-01-01'));
$sql_date_to = fixDate($_POST['date_to'], add_date(date('Y-m-d')));
$patient_id = trim($_POST["patient_id"]);
$age_from = $_POST["age_from"];
$age_to = $_POST["age_to"];
$sql_gender = $_POST["gender"];
$sql_ethnicity = $_POST["ethnicity"];
$sql_race = $_POST["race"];
$form_drug_name = trim($_POST["form_drug_name"]);
$form_diagnosis = trim($_POST["form_diagnosis"]);
$form_lab_results = trim($_POST["form_lab_results"]);
$form_service_codes = trim($_POST["form_service_codes"]);
?>
<html>
<head>
<?php
html_header_show();
示例6: foreach
++$i;
}
return $i;
}
// If we are saving, then save and close the window.
//
if ($_POST['form_save']) {
$i = 0;
$text_type = "unknown";
foreach ($ISSUE_TYPES as $key => $value) {
if ($i++ == $_POST['form_type']) {
$text_type = $key;
}
}
$form_begin = fixDate($_POST['form_begin'], '');
$form_end = fixDate($_POST['form_end'], '');
if ($text_type == 'football_injury') {
$form_injury_part = $_POST['form_injury_part'];
$form_injury_type = $_POST['form_injury_type'];
} else {
$form_injury_part = $_POST['form_medical_system'];
$form_injury_type = $_POST['form_medical_type'];
}
if ($issue) {
$query = "UPDATE lists SET " . "type = '" . $text_type . "', " . "title = '" . $_POST['form_title'] . "', " . "comments = '" . $_POST['form_comments'] . "', " . "begdate = " . QuotedOrNull($form_begin) . ", " . "enddate = " . QuotedOrNull($form_end) . ", " . "returndate = " . QuotedOrNull($form_return) . ", " . "diagnosis = '" . $_POST['form_diagnosis'] . "', " . "occurrence = '" . $_POST['form_occur'] . "', " . "classification = '" . $_POST['form_classification'] . "', " . "reinjury_id = '" . $_POST['form_reinjury_id'] . "', " . "referredby = '" . $_POST['form_referredby'] . "', " . "injury_grade = '" . $_POST['form_injury_grade'] . "', " . "injury_part = '" . $form_injury_part . "', " . "injury_type = '" . $form_injury_type . "', " . "outcome = '" . $_POST['form_outcome'] . "', " . "destination = '" . $_POST['form_destination'] . "', " . "reaction ='" . $_POST['form_reaction'] . "' " . "WHERE id = '{$issue}'";
sqlStatement($query);
if ($text_type == "medication" && enddate != '') {
sqlStatement('UPDATE prescriptions SET ' . 'medication = 0 where patient_id = ' . $thispid . " and upper(trim(drug)) = '" . strtoupper($_POST['form_title']) . "' " . ' and medication = 1');
}
} else {
$issue = sqlInsert("INSERT INTO lists ( " . "date, pid, type, title, activity, comments, begdate, enddate, returndate, " . "diagnosis, occurrence, classification, referredby, user, groupname, " . "outcome, destination, reinjury_id, injury_grade, injury_part, injury_type, " . "reaction " . ") VALUES ( " . "NOW(), " . "'{$thispid}', " . "'" . $text_type . "', " . "'" . $_POST['form_title'] . "', " . "1, " . "'" . $_POST['form_comments'] . "', " . QuotedOrNull($form_begin) . ", " . QuotedOrNull($form_end) . ", " . QuotedOrNull($form_return) . ", " . "'" . $_POST['form_diagnosis'] . "', " . "'" . $_POST['form_occur'] . "', " . "'" . $_POST['form_classification'] . "', " . "'" . $_POST['form_referredby'] . "', " . "'" . ${$_SESSION}['authUser'] . "', " . "'" . ${$_SESSION}['authProvider'] . "', " . "'" . $_POST['form_outcome'] . "', " . "'" . $_POST['form_destination'] . "', " . "'" . $_POST['form_reinjury_id'] . "', " . "'" . $_POST['form_injury_grade'] . "', " . "'" . $form_injury_part . "', " . "'" . $form_injury_type . "', " . "'" . $_POST['form_reaction'] . "' " . ")");
示例7: 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");
}
}
示例8: fwrite
if (PEAR::isError($success)) {
fwrite(STDERR, "Error, failed to add instrument ({$testName}) to the battery for timepoint ({$sessionID}):\n" . $success->getMessage() . "\n");
return false;
}
break;
/**
* Fixing the dates
* arguments: $candID, $dateType, $newDate, $sessionID
*/
/**
* Fixing the dates
* arguments: $candID, $dateType, $newDate, $sessionID
*/
case 'fix_date':
// fix the date (arguments are checked by the function
$success = fixDate($candID, $dateType, $newDate, $sessionID);
if (PEAR::isError($success)) {
fwrite(STDERR, "Failed to fix the date ({$newDate}) of type ({$dateType}) for candidate ({$candID}) [timepoint ({$sessionID})]:\n" . $success->getMessage() . "\n");
return false;
}
break;
/**
* Timepoint Diagnostics
* Recommended: run the diagnostics once the dates have been fixed, you can also pass the 'correct' date and the date type to see what changes would happen if the dates were different
*/
/**
* Timepoint Diagnostics
* Recommended: run the diagnostics once the dates have been fixed, you can also pass the 'correct' date and the date type to see what changes would happen if the dates were different
*/
case 'diagnose':
if (!empty($sessionID)) {
示例9: loadColumnData
function loadColumnData($key, $row)
{
global $areport, $arr_titles, $from_date, $to_date, $arr_show;
// If no result, do nothing.
if (empty($row['abnormal'])) {
return;
}
// If first instance of this key, initialize its arrays.
if (empty($areport[$key])) {
$areport[$key] = array();
$areport[$key]['.prp'] = 0;
// previous pid
$areport[$key]['.wom'] = 0;
// number of positive results for women
$areport[$key]['.men'] = 0;
// number of positive results for men
$areport[$key]['.neg'] = 0;
// number of negative results
$areport[$key]['.age'] = array(0, 0, 0, 0, 0, 0, 0, 0, 0);
// age array
foreach ($arr_show as $askey => $dummy) {
if (substr($askey, 0, 1) == '.') {
continue;
}
$areport[$key][$askey] = array();
}
}
// Flag this patient as having been encountered for this report row.
$areport[$key]['.prp'] = $row['pid'];
// Collect abnormal results only, except for a column of total negatives.
if ($row['abnormal'] == 'no') {
++$areport[$key]['.neg'];
return;
}
// Increment the correct sex category.
if (strcasecmp($row['sex'], 'Male') == 0) {
++$areport[$key]['.men'];
} else {
++$areport[$key]['.wom'];
}
// Increment the correct age category.
$age = getAge(fixDate($row['DOB']), $row['date_ordered']);
$i = min(intval(($age - 5) / 5), 8);
if ($age < 11) {
$i = 0;
}
++$areport[$key]['.age'][$i];
// For each patient attribute to report, this increments the array item
// whose key is the attribute's value. This works well for list-based
// attributes. A key of "Unspecified" is used where the attribute has
// no assigned value.
foreach ($arr_show as $askey => $dummy) {
if (substr($askey, 0, 1) == '.') {
continue;
}
$status = empty($row[$askey]) ? 'Unspecified' : $row[$askey];
$areport[$key][$askey][$status] += 1;
$arr_titles[$askey][$status] += 1;
}
}
示例10: displayLatestMessageBoardPosts
/**
* displayLatestMessageBoardPosts
*
* @param int $memberId
*
* @return void
*/
function displayLatestMessageBoardPosts($memberId)
{
$memberId = (int) $memberId;
$sql = "SELECT t.`id`, `subject`, `date`, `post` \n FROM `fcms_board_posts` AS p, `fcms_board_threads` AS t, `fcms_users` AS u \n WHERE t.`id` = p.`thread` \n AND p.`user` = u.`id` \n AND u.`id` = ?\n ORDER BY `date` DESC \n LIMIT 0, 5";
$rows = $this->fcmsDatabase->getRows($sql, $memberId);
if ($rows === false) {
$this->fcmsError->displayError();
return;
}
if (count($rows) <= 0) {
return;
}
echo '
<h2>' . T_('Latest Posts') . '</h2>';
$tzOffset = getTimezone($memberId);
foreach ($rows as $row) {
$date = fixDate(T_('F j, Y, g:i a'), $tzOffset, $row['date']);
$subject = $row['subject'];
$post = removeBBCode($row['post']);
$post = cleanOutput($post);
$pos = strpos($subject, '#ANOUNCE#');
if ($pos !== false) {
$subject = substr($subject, 9, strlen($subject) - 9);
}
$subject = cleanOutput($subject);
echo '
<p>
<a href="messageboard.php?thread=' . $row['id'] . '">' . $subject . '</a>
<span class="date">' . $date . '</span><br/>
' . $post . '
</p>';
}
}
示例11: LWDate
function LWDate($field)
{
$tmp = fixDate($field);
return substr($tmp, 5, 2) . substr($tmp, 8, 2) . substr($tmp, 0, 4);
}
示例12: loadColumnData
function loadColumnData($key, $row, $quantity = 1)
{
global $areport, $arr_titles, $form_content, $from_date, $to_date, $arr_show;
// If first instance of this key, initialize its arrays.
if (empty($areport[$key])) {
$areport[$key] = array();
$areport[$key]['.prp'] = 0;
// previous pid
$areport[$key]['.wom'] = 0;
// number of services for women
$areport[$key]['.men'] = 0;
// number of services for men
$areport[$key]['.age2'] = array(0, 0);
// age array
$areport[$key]['.age9'] = array(0, 0, 0, 0, 0, 0, 0, 0, 0);
// age array
foreach ($arr_show as $askey => $dummy) {
if (substr($askey, 0, 1) == '.') {
continue;
}
$areport[$key][$askey] = array();
}
}
// Skip this key if we are counting unique patients and the key
// has already seen this patient.
if ($form_content == '2' && $row['pid'] == $areport[$key]['.prp']) {
return;
}
// If we are counting new acceptors, then require a unique patient
// whose contraceptive start date is within the reporting period.
if ($form_content == '3') {
// if ($row['pid'] == $areport[$key]['prp']) return;
if ($row['pid'] == $areport[$key]['.prp']) {
return;
}
// Check contraceptive start date.
if (!$row['contrastart'] || $row['contrastart'] < $from_date || $row['contrastart'] > $to_date) {
return;
}
}
// If we are counting new clients, then require a unique patient
// whose registration date is within the reporting period.
if ($form_content == '4') {
if ($row['pid'] == $areport[$key]['.prp']) {
return;
}
// Check registration date.
if (!$row['regdate'] || $row['regdate'] < $from_date || $row['regdate'] > $to_date) {
return;
}
}
// Flag this patient as having been encountered for this report row.
// $areport[$key]['prp'] = $row['pid'];
$areport[$key]['.prp'] = $row['pid'];
// Increment the correct sex category.
if (strcasecmp($row['sex'], 'Male') == 0) {
$areport[$key]['.men'] += $quantity;
} else {
$areport[$key]['.wom'] += $quantity;
}
// Increment the correct age categories.
$age = getAge(fixDate($row['DOB']), $row['encdate']);
$i = min(intval(($age - 5) / 5), 8);
if ($age < 11) {
$i = 0;
}
$areport[$key]['.age9'][$i] += $quantity;
$i = $age < 25 ? 0 : 1;
$areport[$key]['.age2'][$i] += $quantity;
foreach ($arr_show as $askey => $dummy) {
if (substr($askey, 0, 1) == '.') {
continue;
}
$status = empty($row[$askey]) ? 'Unspecified' : $row[$askey];
$areport[$key][$askey][$status] += $quantity;
$arr_titles[$askey][$status] += $quantity;
}
}
示例13: bucks
// encounters within the specified time period for patients without
// insurance.
require_once "../globals.php";
require_once "{$srcdir}/patient.inc";
require_once "{$srcdir}/sql-ledger.inc";
require_once "{$srcdir}/formatting.inc.php";
$alertmsg = '';
function bucks($amount)
{
if ($amount) {
return oeFormatMoney($amount);
}
return "";
}
$form_start_date = fixDate($_POST['form_start_date'], date("Y-01-01"));
$form_end_date = fixDate($_POST['form_end_date'], date("Y-m-d"));
$INTEGRATED_AR = $GLOBALS['oer_config']['ws_accounting']['enabled'] === 2;
if (!$INTEGRATED_AR) {
SLConnect();
}
?>
<html>
<head>
<?php
html_header_show();
?>
<style type="text/css">
/* specifically include & exclude from printing */
@media print {
#report_parameters {
示例14: fixDate
<?php
// Copyright (C) 2006-2015 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.
// This report lists patients that were seen within a given date
// range.
require_once "../globals.php";
require_once "{$srcdir}/patient.inc";
require_once "{$srcdir}/formatting.inc.php";
$from_date = fixDate($_POST['form_from_date'], date('Y-01-01'));
$to_date = fixDate($_POST['form_to_date'], date('Y-12-31'));
if ($_POST['form_labels']) {
header("Pragma: public");
header("Expires: 0");
header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
header("Content-Type: application/force-download");
header("Content-Disposition: attachment; filename=labels.txt");
header("Content-Description: File Transfer");
} else {
?>
<html>
<head>
<?php
html_header_show();
?>
<style type="text/css">
/* specifically include & exclude from printing */
示例15: handleLunchSpecial
require ADCHEATSHEET;
require CLASS_LUNCHSPECIAL;
$lunch = new handleLunchSpecial();
?>
<?php
getHeader("admin");
?>
<h3>Lunch Specials</h3>
<table class="form">
<tr>
<td class="field-name">Date:</td>
<td class="field-value"><?php
echo fixDate($lunch->date);
?>
</td>
<td></td>
</tr>
<tr>
<td class="field-name">Views:</td>
<td class="field-value"><?php
echo number_format($lunch->views);
?>
</td>
<td></td>
</tr>
<tr>
<td class="field-name">Options:</td>
<td class="field-value"><a href="lunch_special_manage.php?menuid=<?php