Re: mysql session storage handler
| From: | stanojr at blackhole dot websupport dot sk | Date: | Tue, 22 Nov 2005 22:42:53 +0000 |
| Subject: | Re: mysql session storage handler | ||
| References: | 1 2 | Groups: | php.pecl.dev |
| Request: | Send a blank email to pecl-dev+get-3256@lists.php.net to get a copy of this message | ||
hi
> 1. Would it be possible to tie this into PDO so its not mysql specific?
i think it is good idea, but i dont change it to PDO, i dont have time for this,
probably next year :)
>
> 2. Table names should be configurable so for example someone could have
> user_phpsession and admin_phpsession.
i add this thing to next release
actually you cannot change session_mysql.db value in .htaccess nor httpd.conf
because i dont use standard PHP_INI function for this variable
i parse it only 1 time in MINIT function (it must be hidden in phpinfo() and
ini_get functions)
>
> 3. Call back function ability on session_mysql_gc would be nice, This
> way for example a person could log session lengths or maybe save special
> per user settings into the db for per storage.
i think it will not be useful, because gc can be waked on any script anytime
and if you use virtual hosting, some users can obtain some data
of other users sessions
but if you want know session length, you can call this sql query
select sess_host,count(sess_host) from phpsession group by sess_host order by 2 desc limit 10;
sorted by biggest length