#37199 [Opn->Bgs]: XMLReader doesnt accept array properties

From: Date: Tue, 25 Apr 2006 15:33:46 +0000
Subject: #37199 [Opn->Bgs]: XMLReader doesnt accept array properties
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-96219@lists.php.net to get a copy of this message
ID: 37199 Updated by: pajoye@php.net Reported By: evert at collab dot nl -Status: Open +Status: Bogus Bug Type: *XML functions Operating System: Slackware 10 PHP Version: 5.1.2 New Comment: Thank you for taking the time to report a problem with PHP. Unfortunately you are not using a current version of PHP -- the problem might already be fixed. Please download a new PHP version from http://www.php.net/downloads.php If you are able to reproduce the bug with one of the latest versions of PHP, please change the PHP version on this bug report to the version you tested and change the status back to "Open". Again, thank you for your continued support of PHP. Already fixed in CVS and 5.1.3RC3 http://downloads.php.net/ilia/php-5.1.3RC3.tar.bz2 Previous Comments: ------------------------------------------------------------------------ [2006-04-25 15:24:03] evert at collab dot nl Description: ------------ When i create a new class, derived from XMLReader and I add new (private) properties it works perfectly for simple values (int, string), but when I use arrays, it simply forgets the value. Reproduce code: --------------- <?php class MyReader extends XMLReader { private $test; private $arr = array(); public function test() { // Adding a normal variable works just fine: $this->test = 'test'; echo($this->test); // But an array.. is a different story $this->arr[0] = '1'; print_r($this->arr); die(); } } $v = new MyReader(); $v->test(); ?> Expected result: ---------------- testArray(0=>'1') or something along those lines Actual result: -------------- testArray() ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=37199&edit=1

« previous php.bugs (#96219) next »