|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2006-06-12 19:08 UTC] jerome at jeremyknope dot com
[2006-06-13 13:28 UTC] m dot leuffen at i-line dot net
[2006-06-19 12:45 UTC] tony2001@php.net
[2006-06-19 13:53 UTC] jerome at jeremyknope dot com
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Nov 04 21:00:01 2025 UTC |
Description: ------------ When upgrading to Kubuntu or Ubuntu 6.06 (or even previous Dapper Dragon pre-releases), SOAP extension in PHP 5.1.4 stops functioning the way it used to regarding the XML responses. Associative arrays no longer return a XML response that specifies type. Reproduce code: --------------- class MyService { function getLists() { $out = array( array( 'id' => 12, 'name' => 'My New List' ) ); return $out; } } In a client page: $result = $client->getLists(); $result will be stdClass stuff on 'broken' setup, with dapper. Expected result: ---------------- Snippet of XML response from a $client->getLists() call: <SOAP-ENV:Body> <ns1:getListsResponse> <getListsReturn SOAP-ENC:arrayType="ns2:Map[1]" xsi:type="SOAP-ENC:Array"> <item xsi:type="ns2:Map"> <item> <key xsi:type="xsd:string">id</key> <value xsi:type="xsd:string">12</ value> </item> <item> <key xsi:type="xsd:string">name</ key> <value xsi:type="xsd:string">My New List</value> </item> </item> </getListsReturn> </ns1:getListsResponse> </SOAP-ENV:Body> Result variable should be: Array ( [0] => Array ( [id] => 12 [name] => My New List ) ) Actual result: -------------- Actual result, missing type attributes: <SOAP-ENV:Body> <ns1:getListsResponse> <getListsReturn> <item> <item> <key>id</key> <value>12</value> </item> <item> <key>name</key> <value>My New List</value> </item> </item> </getListsReturn> </ns1:getListsResponse> </SOAP-ENV:Body> Actual $result variable on dapper: stdClass Object ( [item] => stdClass Object ( [item] => Array ( [0] => stdClass Object ( [key] => id [value] => 20 ) [1] => stdClass Object ( [key] => name [value] => Test Site List ) ) ) )