|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[1998-09-01 11:44 UTC] zeev
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Wed Dec 17 07:00:01 2025 UTC |
This bug was discovered using the PHP Base Library with PHP 3.0.3. Part of this library essentially performs a call like: eval('$GLOBALS["auth"]=new Album_Auth;'); The problem is that if Album_Auth has a constructor, then a Parse Error occurs on the line containing the closing '}' at the end of the class definition. If there is no constructor, everything is fine. A workaround I found was to modify the code so that the call became: eval('$GLOBALS["auth"]=$this->makeobject("Album_Auth");'); and I defined a the makeobject function as: function makeobject($obj) { return new $obj; } This seems to work fine.