ID:               15110
 Updated by:       [EMAIL PROTECTED]
 Reported By:      [EMAIL PROTECTED]
 Status:           Open
 Bug Type:         Documentation problem
 Operating System: Linux
 PHP Version:      4.1.1
 New Comment:

If you have your own save handler functions, you can do what ever you
want with you functiions. 

For example, if session is new (no record in your DB when read is
called), just insert it when close is called.




Previous Comments:
------------------------------------------------------------------------

[2002-02-08 05:48:50] [EMAIL PROTECTED]

I share a server with a couple of other sites using php and I'm the
only one using mysql to store sessions. By storing all my sessions in a
table, both empty and not, I get a measure of how many sessions my site
has started. This gives me a rough idea of how many vistors I have at a
specfic time, just by counting the rows in the table. Further on, I
differ logged in users by counting those who have the a flag
registered. This gives me fast and rough stats of how many users that
are visisting the site and how many of them who are logged in.
Now, when I get the empty sessions all mixed up with the other sites ut
gets way too rough. I have thought of a couple of possible solutions
with by always registering a variable to session but it makes it more
ineffcient than before.

I think you get the picture. Maybe you have a simple soloution, if so
please share =). I've gotta go now. Have a nice weekend.

------------------------------------------------------------------------

[2002-02-08 02:19:03] [EMAIL PROTECTED]

What is the big problem here exactly? I fail to understand why this is
important for you.

Derick

------------------------------------------------------------------------

[2002-02-07 05:40:15] [EMAIL PROTECTED]

Ah well, since I'm the only one complaining I guess no one will do
anything about it. For me it's back to 4.0 because I really used the
previous way it worked. =/

/Fabbe

------------------------------------------------------------------------

[2002-02-07 04:00:08] [EMAIL PROTECTED]

This is due to implementation difference by nature. "files" save
handler creates session file when _open_ is called. In contrust,
database storage with "user" save handler, there is not need to create
session record when open or read is called. If session is started by
there is no data to save, _write_ is not called for both user and files
handler, but there will be empty sesson data file since it's already
created.

I think this behavior is reasonable. If user don't like certain save
handler behavior, user should use other or implement one by themself.

For example, "session_pgsql" save handler does not even use
"gc_probability" for performance reason. It performs GC with specified
time interval. It also does not return session data when data is
expired.

I mean all save handlers does not work exactly the same way ;)

------------------------------------------------------------------------

[2002-02-07 03:43:16] [EMAIL PROTECTED]

=7

Well, it still stores the session-keys as files when they´re empty,
just not when I want it in a table. I use this to differ my sites
sessions from other sites on the server and I when I had all
sessions(empty or not) in a table I used it for "right" now stats. Now
I get empty session as files with the session key as name and the
sessions with data in my table. This makes it impossible for me to
count how many sessions belong to my site because I'm not the only one
using the server. So WHY are empty sessions stored as files and full
sessions as files when I store them as files BUT when I store the
sessions in a table I get the empty ones in files, along with the other
sites', and the sessions with variables which belong to my site, turn
up in the table as they're supposed to. I WANT all the sessions in ONE
place... =( *going back to 4.0...*

------------------------------------------------------------------------

The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
    http://bugs.php.net/15110

-- 
Edit this bug report at http://bugs.php.net/?id=15110&edit=1


-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to