RE: [PEAR-DEV] PEAR::HTTP_Session
| From: | Ken Kyler | Date: | Mon, 29 Sep 2003 23:34:56 +0000 |
| Subject: | RE: [PEAR-DEV] PEAR::HTTP_Session | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-22191@lists.php.net to get a copy of this message | ||
> Who's gonna take it? Stephan volunteered for the package, I did ...
> hmm ...
>
>
> Well Ken, if you maybe already have ideas on how to improve the
> package I, from my side, would suggest you take it.
Hi Stefan,
Given that extra info, I vote either of you take lead and I'll assist.
This is my recommendation.
function set()
{
session_module_name('user');
session_set_save_handler(
array(& $this, 'HTTP_Session_Open'),
array(& $this, 'HTTP_Session_Close'),
array(& $this, 'HTTP_Session_Read'),
array(& $this, 'HTTP_Session_Write'),
array(& $this, 'HTTP_Session_Destroy'),
array(& $this, 'HTTP_Session_GC')
);
}
// Delegate function calls to the object's methods
/** @ignore */
function HTTP_Session_Open($save_path, $session_name)
{
return $this->open($save_path, $session_name);
}
/** @ignore */
function HTTP_Session_Close(){
return $this->close();
}
/** @ignore */
function HTTP_Session_Read($id)
{
return $this->read($id);
}
/** @ignore */
function HTTP_Session_Write($id, $data)
{
return $this->write($id, $data);
}
/** @ignore */
function HTTP_Session_Destroy($id)
{
return $this->destroy($id);
}
/** @ignore */
function HTTP_Session_GC($maxlifetime)
{
return $this->gc($maxlifetime);
}
Ken