#32188 [NEW]: Problem when extending a standard class

From: Date: Fri, 04 Mar 2005 10:07:33 +0000
Subject: #32188 [NEW]: Problem when extending a standard class
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-74820@lists.php.net to get a copy of this message
From: manu at manucorp dot com Operating system: Linux PHP version: 5.0.3 PHP Bug Type: SimpleXML related Bug description: Problem when extending a standard class Description: ------------ When i extend SimpleXMLElement there is some weird issue on accessing variable of the class. (perhaps related to bug #28817, i'm not completely sure) Reproduce code: --------------- <?php class Reader extends SimpleXMLElement { public $test; public function extract() { $this->test=array(); var_dump(is_array($this->test)); } } $uploadfile="file.xml"; $rs=simplexml_load_file($uploadfile,"Reader"); $rs->extract(); ?> Expected result: ---------------- bool(true) Actual result: -------------- bool(false) -- Edit bug report at http://bugs.php.net/?id=32188&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=32188&r=trysnapshot4 Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=32188&r=trysnapshot50 Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=32188&r=trysnapshot51 Fixed in CVS: http://bugs.php.net/fix.php?id=32188&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=32188&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=32188&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=32188&r=needscript Try newer version: http://bugs.php.net/fix.php?id=32188&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=32188&r=support Expected behavior: http://bugs.php.net/fix.php?id=32188&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=32188&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=32188&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=32188&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=32188&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=32188&r=dst IIS Stability: http://bugs.php.net/fix.php?id=32188&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=32188&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=32188&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=32188&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=32188&r=mysqlcfg

« previous php.bugs (#74820) next »