Re: RE:[PHP] sessions...how to use not clear?

From: Date: Tue, 23 Mar 2004 00:28:16 +0000
Subject: Re: RE:[PHP] sessions...how to use not clear?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-181201@lists.php.net to get a copy of this message
Andy B wrote:
WHy do we need to have a session name for that? because eventually i want to take the user name (session name/variables/user info) and create a preferences section of the website im doing and that would require a constant session name from visit to visit
Ummm... that's why you set a $_SESSION['username'] value. You really don't need to worry about the name or id of the session (other than resetting it upon login to prevent Session Fixation Attacks). Sessions are for the current visit, page to page, not to "remember" things across multiple visits. Cookies are used for that (but be aware of security issues there, also, depending on how you implement them). -- ---John Holmes... Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/ php|architect: The Magazine for PHP Professionals – www.phparch.com

« previous php.general (#181201) next »