Re: passing session ID

From: Date: Thu, 22 Jan 2004 15:53:08 +0000
Subject: Re: passing session ID
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-175428@lists.php.net to get a copy of this message
--- Diana Castillo <diana@interhotel.com> wrote: > If I want to store a session id in a database, how would I do it, like > this? > $session_id=SID ; ? > and then if I want to retrieve this session id and get all of the info > back that goes with this session id, I would say session_start() and > then what? You probably want to read the PHP manual pretty well, because this question makes no sense. You don't need to store the session identifier in a session; it's akin to the primary key that you use to identify a particular user's record in the session data store. Also, PHP does all of this. There's no need for you to be manually implementing your own session storage and retrieval functions, especially if you don't understand how sessions work. Hope that helps. Chris ===== Chris Shiflett - http://shiflett.org/ PHP Security Handbook Coming mid-2004 HTTP Developer's Handbook http://httphandbook.org/

« previous php.general (#175428) next »