note 13638 deleted from language.oop.magic-functions by danbrown
| From: | danbrown@php.net | Date: | Sat, 07 Nov 2009 18:55:19 +0000 |
| Subject: | note 13638 deleted from language.oop.magic-functions by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-162517@lists.php.net to get a copy of this message | ||
Note Submitter: agland at squiz dot net
----
echoing output (even debugging statements) seems to cause problems in the __sleep() magic function.
I suspect this is because, in the case of sessions, PHP is saving the session information (and
running __sleep() in your object) after all the output has theoretically all been sent.
This resulted in the serialized object appearing as an empty string in our session files.