Zum Inhalt springen

$GLOBALS["TSFE"] wo eintragen ?

Erstellt am 15. Mai 2009 · 1 Antwort · letzte Antwort am 15. Mai 2009

Tags: Frage

ava99 ·

Hallo

Habe auf einer Seite von Typo3 ein Wiki gefunden
http://wiki.typo3.org/Table_of_Contents_(XDG)#Using_sessions

Da wird erwähnt, dass man folgendes eintragen soll,

$my_vars = $GLOBALS["TSFE"]->fe_user->getKey('ses','tx_myextension_mykey');

you then will add your own values the same way:

$my_vars['somevalue'] = "Hello World";

Again, Don't forget to save the data to the session in the end:

$GLOBALS["TSFE"]->fe_user->setKey('ses','tx_myextension_mykey',$my_vars);
$GLOBALS["TSFE"]->storeSessionData();

mir ist nicht ganz klar, wo ich das eintragen soll, in die entsprechende Extension ?

Danke schon für eure Hilfe
MFG