- modules/fotolab updated imagej to current version & some cod fixes to make it work
[care2x.git] / Care2007 / modules / registration_admission / patient_register.php
blobc51a0104639d71c18dfeeaca488fe2b3e4fd64d0
1 <?php
2 error_reporting(E_COMPILE_ERROR|E_ERROR|E_CORE_ERROR);
3 require('./roots.php');
4 require($root_path.'include/inc_environment_global.php');
5 /**
6 * CARE2X Integrated Hospital Information System beta 2.0.1 - 2004-07-04
7 * GNU General Public License
8 * Copyright 2002,2003,2004,2005,2006 Elpidio Latorilla
9 * elpidio@care2x.org,
11 * See the file "copy_notice.txt" for the licence notice
13 $lang_tables[]='emr.php';
14 $lang_tables[]='person.php';
15 $lang_tables[]='date_time.php';
16 define('LANG_FILE','aufnahme.php');
18 $local_user='aufnahme_user';
19 require($root_path.'include/inc_front_chain_lang.php');
21 //$db->debug=true;
23 $thisfile=basename(__FILE__);
24 $default_filebreak=$root_path.'main/startframe.php'.URL_APPEND;
26 if(empty($HTTP_SESSION_VARS['sess_path_referer']) || !file_exists($root_path.$HTTP_SESSION_VARS['sess_path_referer'])) {
27 $breakfile=$default_filebreak;
28 } else {
29 $breakfile=$root_path.$HTTP_SESSION_VARS['sess_path_referer'].URL_APPEND;
32 if(!session_is_registered('sess_pid')) session_register('sess_pid');
33 if(!isset($insurance_show)) $insurance_show=true;
35 $newdata=1;
36 $target='entry';
38 # Start Smarty templating here
39 /**
40 * LOAD Smarty
43 # Note: it is advisable to load this after the inc_front_chain_lang.php so
44 # that the smarty script can use the user configured template theme
46 require_once($root_path.'gui/smarty_template/smarty_care.class.php');
47 $smarty = new smarty_care('common');
49 # Title in the toolbar
51 $smarty->assign('sToolbarTitle',$LDPatientRegister);
53 # href for help button
54 $smarty->assign('pbHelp',"javascript:gethelp('submenu1.php','$LDPatientRegister')");
56 $smarty->assign('breakfile',$breakfile);
58 # Window bar title
59 $smarty->assign('title',$LDPatientRegister);
61 $smarty->assign('sOnLoadJs',"if (window.focus) window.focus();");
63 $smarty->assign('pbHelp',"javascript:gethelp('person_reg_newform.php','".$error."','".$error_person_exists."')");
65 # Hide the return button
66 $smarty->assign('pbBack',FALSE);
68 /* Create the tabs */
69 $tab_bot_line='#66ee66';
70 require('./gui_bridge/default/gui_tabs_patreg.php');
73 require_once($root_path.'include/care_api_classes/class_gui_input_person.php');
75 $inperson = & new GuiInputPerson;
77 $inperson->setPID($pid);
78 $inperson->pretext = $sTemp;
79 $inperson->setDisplayFile('patient_register_show.php');
81 $sRegForm=$inperson->create();
83 $smarty->assign('sRegForm',$sRegForm);
85 $smarty->assign('sSearchLink','<img '.createComIcon($root_path,'varrow.gif','0').'> <a href="patient_register_search.php'.URL_APPEND.'">'.$LDPatientSearch.'</a>');
86 $smarty->assign('sArchiveLink','<img '.createComIcon($root_path,'varrow.gif','0').'> <a href="patient_register_archive.php'.URL_APPEND.'&newdata=1&from=entry">'.$LDArchive.'</a>');
88 $sCancel="<a href=";
89 if($HTTP_COOKIE_VARS['ck_login_logged'.$sid]) $sCancel.=$breakfile;
90 else $sCancel.='aufnahme_pass.php';
91 $sCancel.=URL_APPEND.'><img '.createLDImgSrc($root_path,'cancel.gif','0').' alt="'.$LDCancelClose.'"></a>';
93 $smarty->assign('pbCancel',$sCancel);
95 $smarty->assign('sMainBlockIncludeFile','registration_admission/reg_input.tpl');
97 $smarty->display('common/mainframe.tpl');