[development] Sessions and non-logged-in users
kb at 2bits.com
Tue May 16 22:01:35 UTC 2006
> * and then Khalid B declared....
> > Use session data.
> > To store something use:
> > $_SESSION['foo'] = $bar;
> > To get it back use:
> > $baz = $_SESSION['foo'];
> > That is it.
> Will the data not be lost when the browser is closed?
Session data are stored in drupal's sessions table, and
cross referenced with an SID that is stored in the PHPSESSID
cookie on the user's machine.
So, the data will be lost if that PHPSESSID cookie for the site
More information about the development