while ($encounter = $result->FetchRow()) { if ($type == "R") { $registration_fee = $encounter['article']; } else { if ($type == "C") { $consultation_fee = $encounter['article']; } } } $type = "C"; } } include_once $root_path . 'include/inc_date_format_functions.php'; /* Update History */ if (!$newdata) { $encounter_obj->setHistorySeen($_SESSION['sess_user_name'], $encounter_nr); } /* Get insurance firm name*/ $insurance_firm_name = $insurance_obj->getFirmName($insurance_firm_id); /* Check whether config path exists, else use default path */ $photo_path = is_dir($root_path . $GLOBAL_CONFIG['person_foto_path']) ? $GLOBAL_CONFIG['person_foto_path'] : $default_photo_path; /* Prepare text and resolve the numbers */ require_once $root_path . 'include/inc_patient_encounter_type.php'; /* Save encounter nrs to session */ $_SESSION['sess_pid'] = $pid; $_SESSION['sess_en'] = $encounter_nr; $_SESSION['sess_full_en'] = $full_en; $_SESSION['sess_parent_mod'] = 'admission'; $_SESSION['sess_user_origin'] = 'admission'; $_SESSION['sess_file_return'] = $thisfile; /* Prepare the photo filename */