note 97366 added to function.xmlrpc-encode
| From: | Anonymous at osu1 dot php dot net | Date: | Thu, 15 Apr 2010 23:51:17 +0000 |
| Subject: | note 97366 added to function.xmlrpc-encode | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-168306@lists.php.net to get a copy of this message | ||
Many people have complained about the indexed array bug. Will this bug ever be fixed?
$a=array(1=>'one', '3'=>'three', 5=>'five',
'a'=>'foo');
print_r($a);
print_r(xmlrpc_decode(xmlrpc_encode($a)));
Returns:
Array
(
[1] => one
[3] => three
[5] => five
[a] => foo
)
Array
(
[0] => one
[1] => three
[2] => five
[a] => foo
)
The keys are lost if they have a numeric value even if they are set to type string.
There was said that it wont be fixed:
http://bugs.php.net/21949
http://bugs.php.net/37746
There was said that it was fixed:
http://bugs.php.net/50285
However it wasn't fixed I still have the problem on PHP 5.3.1.
----
Server IP: 69.147.83.197
Probable Submitter: 84.72.11.27
----
Manual Page -- http://www.php.net/manual/en/function.xmlrpc-encode.php
Edit -- https://master.php.net/note/edit/97366
Del: integrated -- https://master.php.net/note/delete/97366/integrated
Del: useless -- https://master.php.net/note/delete/97366/useless
Del: bad code -- https://master.php.net/note/delete/97366/bad+code
Del: spam -- https://master.php.net/note/delete/97366/spam
Del: non-english -- https://master.php.net/note/delete/97366/non-english
Del: in docs -- https://master.php.net/note/delete/97366/in+docs
Del: other reasons-- https://master.php.net/note/delete/97366
Reject -- https://master.php.net/note/reject/97366
Search -- https://master.php.net/manage/user-notes.php