Re: PEAR::Auth - cookies and @session_start()

From: Date: Mon, 14 Jun 2004 02:44:13 +0000
Subject: Re: PEAR::Auth - cookies and @session_start()
References: 1 2  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-13133@lists.php.net to get a copy of this message
On Jun 13, 2004, at 9:35 PM, Michael Ark wrote:
[Thanks, Paul, for the answer on $expire/$idle: that answered it for me.] Is it necessary to have an explicit session_start() when you implement Auth? I am using version 1.2.3, and looking at the source code it would seem that @session_start is done when you do a
        $a -> start()
but this is not happening. At least, I am not getting cookies set. I saw an online implementation that used an explicit session_start at the top of the file
I do the same thing in the Yawp (http://phpyawp.com) foundation (but only because Auth is an optional component in Yawp and I need to make sure the session starts no matter what). However, I do some session_set_cookie_params() before calling session_start. Perhaps you need to se the session path or domain for the session cookie. Don't know for sure. Perhaps taking out the @ in your local Auth code will reveal the error; if it does not, perhaps Martin Jansen can shed some light. -- Paul M. Jones Savant: the simple alternative to Smarty for PHP. http://phpsavant.com/ DB_Table: build RDBMS tables and XHTML forms in one PHP class. http://wiki.ciaweb.net/yawiki/index.php?area=DB_Table Yawiki: your collaborative online documentation system. http://yawiki.com/ Yawp: a single-file foundation for PHP applications. http://phpyawp.com/

« previous php.pear.general (#13133) next »