note 64295 added to function.session-register
| From: | martijn at brothersinart dot net | Date: | Tue, 11 Apr 2006 21:04:31 +0000 |
| Subject: | note 64295 added to function.session-register | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-107811@lists.php.net to get a copy of this message | ||
Please note that if you use a "|" sign in a variable name your entire session will be
cleared, so the example below will clear out all the contents of your session.
<?php
session_start();
$_SESSION["foo|bar"] = "foo";
?>
It took me quite some time finding out why my session data kept disappearing. According to this
bugreport this behaviour is intended.
http://bugs.php.net/bug.php?id=33786
----
Server IP: 83.137.20.120
Probable Submitter: 194.122.35.185
----
X-Spam-Status: No, hits=3.1 required=5.0 tests=DATE_MISSING,FROM_NO_LOWER
autolearn=no version=2.64
----
Manual Page -- http://www.php.net/manual/en/function.session-register.php
Edit -- http://master.php.net/note/edit/64295
Del: integrated -- http://master.php.net/note/delete/64295/integrated
Del: useless -- http://master.php.net/note/delete/64295/useless
Del: bad code -- http://master.php.net/note/delete/64295/bad+code
Del: spam -- http://master.php.net/note/delete/64295/spam
Del: non-english -- http://master.php.net/note/delete/64295/non-english
Del: in docs -- http://master.php.net/note/delete/64295/in+docs
Del: other reasons-- http://master.php.net/note/delete/64295
Reject -- http://master.php.net/note/reject/64295
Search -- http://master.php.net/manage/user-notes.php