[TYPO3-english] Clear FE user session data on logoff
Victor Livakovsky
v-tyok at mail.ru
Tue Dec 13 11:54:24 CET 2011
Hi, Jigal.
> If you want to store data about a logged in user you can use
> setKey('user', $name, $data). This will even survive between logins.
Yes, I also was looking into this, but I don't need so long life of data, so
I rejected this way and made it a bit different: $name variable contains uid
of current FE user appended - this makes sure, that only concrete user will
see his related data.
> As far as I could see in the code if a FE user logs off the session data
> should be removed. However, if you want to be absolutely sure, there is a
> hook
> $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_userauth.php']['logoff_pre_processing']
> inside the logoff() function.
> You could make a hook subscriber which calls
> $GLOBALS['TSFE']->fe_user->removeSessionData() .
Thank you! That sounds good, so I'll make an implementation :)
More information about the TYPO3-english
mailing list