|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2004-05-17 23:28 UTC] magicking89 at hotmail dot com
[2005-04-01 13:52 UTC] maka3d at yahoo dot com dot br
[2005-04-14 10:23 UTC] vrana@php.net
[2005-04-22 01:00 UTC] phpdoc at lists dot php dot net
[2005-05-30 10:02 UTC] lsmith@php.net
[2005-05-30 10:04 UTC] lsmith@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Oct 30 07:00:02 2025 UTC |
Description: ------------ If you create a __call() method for a class, and then try to serialize it yourself, or store an object of that class in $_SESSION, you need to either explicitly define a __sleep() method as well, or make sure that __call() will respond appropriately. Otherwise serialize() will complain. It seems unlikely that this is a bug, though I suppose it might be a feature request. So it should just be spelled out in the documentation for __call() when that gets written. Reproduce code: --------------- class foo { function __call() { return; } } $a = new foo; serialize($a); Expected result: ---------------- n/a Actual result: -------------- n/a