Bug #10604: couldnt update a session var or just register one
| From: | jose dot plans at wanadoo dot fr | Date: | Wed, 02 May 2001 09:55:14 +0000 |
| Subject: | Bug #10604: couldnt update a session var or just register one | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-53302@lists.php.net to get a copy of this message | ||
From: jose.plans@wanadoo.fr
Operating system: linux (redhat 7.0)
PHP version: 4.0.4pl1
PHP Bug Type: *Session related
Bug description: couldnt update a session var or just register one
Hi and sorry to disturb but i have a pb
and i dont know if is it a bug or something
else, hope is not a bug!
maybe the problem comes from the compilation,
maybe from me, but when i do :
-------------- SESSION PB -------------------
session_start();
$ID=session_id(); $WHAT=$pass.$ID;
if(!$SID){
session_register("SID");
$SID=md5($WHAT);
}else{
$LOCAL_SID=md5($WHAT);
if($SID!=$LOCAL_SID){
session_destroy();
?><script>alert("ops...");</script><?
}
}
----------------------------------------------
and i do :
echo session_encode();
i get :
----------------------------------------------
usr_pro|s:1:"1";usr_key|s:1:"1";connected|i:1;usr_log|s:3:"flo";!SID|secteur|s:1:"2";
with SID unset...
and other pb is that i cannot update a session var:
session_unregister('toto');
session_register('toto');
when this is done, i got the same values from toto.... :-(
thanks for all !
regards,
José PLANS
--
Edit Bug report at: http://bugs.php.net/?id=10604&edit=1