示例#1
0
        include 'pages/' . $environment->getCurrentModule() . '_' . $environment->getCurrentFunction() . '.php';
    }
} else {
    $page->addErrorView($errorbox);
}
// display page
echo $page->asHTML();
flush();
/*********** SAVE SESSION ***********/
// save session with history information
if ($environment->getCurrentFunction() != 'getfile' and $environment->getCurrentModule() != 'help' and !empty($session)) {
    $history = $session->getValue('history');
    $current_page['context'] = $environment->getCurrentContextID();
    $current_page['module'] = $environment->getCurrentModule();
    $current_page['function'] = $environment->getCurrentFunction();
    $current_page['parameter'] = $environment->getCurrentParameterArray();
    if (empty($history)) {
        $history[0] = $current_page;
    } else {
        $new_history[0] = $current_page;
        if ($new_history[0] != $history[0]) {
            $history = array_merge($new_history, $history);
        }
    }
    while (count($history) > 5) {
        array_pop($history);
    }
    $session->setValue('history', $history);
    // kann sich die session nicht selbst speichern ???
    $session_manager = $environment->getSessionManager();
    $session_manager->save($session);
示例#2
0
文件: commsy.php 项目: a2call/commsy
             $session->reset();
             // so session will not saved at redirect
         }
         $url = $_SERVER['SCRIPT_NAME'] . '?' . $_SERVER['QUERY_STRING'];
         if (mb_stristr($url, '&SID=')) {
             $url = mb_substr($url, 0, mb_strpos($url, '&SID='));
         }
         redirect_with_url($url);
     } else {
         $_GET['cs_modus'] = 'password_change';
         $environment->setCurrentModule('home');
         $environment->setCurrentFunction('index');
         if (!$environment->inPortal()) {
             $environment->setCurrentContextID($environment->getCurrentPortalID());
         }
         $environment->getCurrentParameterArray();
         $environment->setCurrentParameter('cs_modus', 'password_change');
     }
 }
 /** password forget (END) **/
 if (isset($session) and mb_strtoupper($session->getValue('user_id'), 'UTF-8') == 'GUEST' and !$outofservice) {
     $cas_ticket = '';
     if (!empty($_GET['ticket'])) {
         $cas_ticket = $_GET['ticket'];
     } elseif (!empty($_POST['ticket'])) {
         $cas_ticket = $_POST['ticket'];
     } elseif (!empty($_COOKIE['ticket'])) {
         $cas_ticket = $_COOKIE['ticket'];
     }
     if (!empty($cas_ticket)) {
         $portal = $environment->getCurrentPortalItem();