Re: session_start/session_write_close creates multiple sessioncookie headers. How to fix this.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Chris wrote:
Mathijs wrote:
Hello again,

I Use session_write_close() so the page loads quicker because i use session on multiple place.
This because session has protection for race conditions.

Now it works very well and i don't have any problems at all.
I only see that there are multiple session cookie headers set.
I Personally think that one is enough :P.

How can i make it so that it just sets just one and not set this header every time i call session_start or session_write_close.
Because i don't know when the cookie is set.

I think this will be an either/or situation.

Either it only sends one session cookie header and you don't use session_write_close all over the place..

or, it sends multiple cookies and you do use session_write_close all over the place.

The internals of php would set this behaviour, not something you can change without changing the C code.


Hmmm...
I find it kinda strange that it sets the same uniqueId with the same session name more then once.
It would be logical to just have one.. And overwrite the previous session cookie.
Any other thing would be an programmers fault in my opinion.
Because you can't have more then one session id per session cookie name.
Also, the browser won't send all the cookies back.
This is just useless overhead.

But it seems that i have to live with it (for now).
I think ill report this as an bug to PHP.

Thx.
Mathijs.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux