Welcome Guest, Not a member yet? Register   Sign In
multiple cookies in page headers
#1

[eluser]druid100[/eluser]
i just noticed that within the page headers there are 5 cookies of the same name, thus increasing the size needed to encode the cookies by roughly 5 times. taking into account that the last cookie wins i did some testing.

it turns out that whenever sess_write in Session.php calls setcookie() a new cookie (of the same name) will be added to the page response headers.

sess_write is called by sess_create, sess_update, set_userdata, unset_userdata. even without calls from myself to set_userdata / unset_userdata the sess_write function is called several times.

i thought that the session lib would collect all session data and perform one setcookie before the page is sent to the browser which would result in one cookie sent to the browser.

can anybody clarify this? is there somethin i do miss in terms of configuration? sending several cookies which overwrite themself to the browser does not seem to be right.




Theme © iAndrew 2016 - Forum software by © MyBB