echo 'Fatal Error. It appears you\'re converting from dotProject.<br/><a href="./install/index.php">' . 'Click Here To Start the Conversion!</a> (forwarded in 5 sec.)</body></html>'; exit; } } else { echo '<html><head><meta http-equiv="refresh" content="5; URL=' . W2P_BASE_URL . '/install/index.php"></head><body>'; echo 'Fatal Error. You haven\'t created a config file yet.<br/><a href="./install/index.php">' . 'Click Here To Start Installation and Create One!</a> (forwarded in 5 sec.)</body></html>'; exit; } require_once W2P_BASE_DIR . '/includes/main_functions.php'; require_once W2P_BASE_DIR . '/includes/db_adodb.php'; $defaultTZ = w2PgetConfig('system_timezone', 'UTC'); $defaultTZ = '' == $defaultTZ ? 'UTC' : $defaultTZ; date_default_timezone_set($defaultTZ); // don't output anything. Usefull for fileviewer.php, gantt.php, etc. $suppressHeaders = w2PgetParam($_GET, 'suppressHeaders', false); $session = new w2p_System_Session(); $session->start(); // write the HTML headers if (!$suppressHeaders) { header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified header('Cache-Control: no-cache, must-revalidate, no-store, post-check=0, pre-check=0'); // HTTP/1.1 header('Pragma: no-cache'); // HTTP/1.0 header("Content-type: text/html; charset=UTF-8"); } // Force POSIX locale (to prevent functions such as strtolower() from messing up UTF-8 strings) setlocale(LC_CTYPE, 'C');
function w2PsessionStart() { trigger_error(__FUNCTION__ . " has been deprecated in v3.2 and will be removed in v5.0. Please use w2p_System_Session->start instead.", E_USER_NOTICE); $session = new w2p_System_Session(); return $session->start(); }
//execute query and fetch results $r->exec(); $boot_query_row = $r->fetchRow(); if ($boot_query_row) { $boot_user_session = $boot_query_row['session_id']; $boot_user_log_id = $boot_query_row['user_access_log_id']; } } } do { if ($boot_user_id == $AppUI->user_id && $boot_user_session == $_COOKIE['PHPSESSID']) { $AppUI->resetPlace(); $AppUI->redirect('logout=-1'); } else { addHistory('login', $boot_user_id, 'logout', $details); $session = new w2p_System_Session(); $session->destroy($boot_user_session, $boot_user_log_id); } if ($boot_query_row) { $boot_query_row = $r->fetchRow(); if ($boot_query_row) { $boot_user_session = $boot_query_row['session_id']; $boot_user_log_id = $boot_query_row['user_access_log_id']; } else { $r->clear(); } } } while ($boot_query_row); $msg = $boot_user_name . ' logged out by ' . $AppUI->user_first_name . ' ' . $AppUI->user_last_name; $AppUI->setMsg($msg, UI_MSG_OK); $AppUI->redirect('m=users&tab=3');