Ticket #1525 (new defect)

Opened 6 years ago

Last modified 6 years ago

LoginMgr::logout destroys session - is this required?

Reported by: biggs Assigned to: somebody
Priority: normal Milestone:
Component: module - user Severity: open
Keywords: user, logout, language Cc:

Description

In the logout command gets the session destroyed:

SGL_Session::destroy();

This leads to the fact that current language settings are no longer available within the HTTP::redirect method and so, he cannot keep the site's language. Can we remove this session destroy call? Or do I have to write a work around? I think keeping current language after logout would be nice.

Change History

08/30/07 04:44:17 changed by biggs

Update: Just removing the destroy call does no longer logout the user. For testing I added code to save the current language before the session gets destroyed and set it after re-creating it again. This would work and can be added in the destroy function.

        $c = &SGL_Config::singleton();
        $conf = $c->getAll();
        if (isset($_SESSION) && isset($_SESSION['aPrefs']['language'])) {
            $curLang = $_SESSION['aPrefs']['language'];
        }
        $sess = & new SGL_Session();
        if (isset($curLang)) {
            $_SESSION['aPrefs']['language'] = $curLang;
        }

One thing I have in mind: When there will be a statistics module in the future, logging out would mean the user will be treated as new user after logout. (Cause it's a new session) So you can not analysis what an user does after logout when he is still on the site. Am i right here?