is this a bug in SoapServer?

php.internals

Ron Korving

19 years ago
Hi, returning array('5' => 'Foo', '10' => 'Bar') from a SoapServer handler class ends up as array(0 => 'Foo', 1 => 'Bar') at the client end. I can hardly imagine this being a feature, but maybe someone can tell me if this is somehow wanted or inevitable behavior. Thanks, Ron Korving

Lukas Kahwe Smith

19 years ago
Ron Korving wrote:
> Hi, > > returning array('5' => 'Foo', '10' => 'Bar') from a SoapServer handler class > ends up as array(0 => 'Foo', 1 => 'Bar') at the client end. I can hardly > imagine this being a feature, but maybe someone can tell me if this is > somehow wanted or inevitable behavior.
I assume its because there is no such thing as an associative array, so the thing ends up being a simple ordered sequence. regards, Lukas

Ron Korving

19 years ago
But array('a' => 'Foo', 'b' => 'Bar') does end up correctly. It only fails with numeric keys. I'm using PHP 5.2.1 by the way. Thanks, Ron "Lukas Kahwe Smith" <mls@pooteeweet.org> schreef in bericht news:461CE9FD.4070108@pooteeweet.org...