note 74263 added to function.soap-soapclient-soapcall

From: Date: Mon, 02 Apr 2007 13:02:40 +0000
Subject: note 74263 added to function.soap-soapclient-soapcall
Groups: php.notes 
Request: Send a blank email to php-notes+get-125015@lists.php.net to get a copy of this message
Note that when a SOAP call returns an array [max_elements=">1"] - you may not actually get an array... (this may be a fault in the wsdl, but it's certainly a potential headache). foreach($result->field as $field) { doSomethingWith($field); } With more than 1 <field>, you'll loop through the <field> tags (as expected)... However, with exactly 1 <field>, you'll instead loop through the child elements of the first <field> (almost certainly *not* what you wanted to happen)... ---- Server IP: 194.145.210.3 Probable Submitter: 213.208.117.249 ---- Manual Page -- http://www.php.net/manual/en/function.soap-soapclient-soapcall.php Edit -- https://master.php.net/note/edit/74263 Del: integrated -- https://master.php.net/note/delete/74263/integrated Del: useless -- https://master.php.net/note/delete/74263/useless Del: bad code -- https://master.php.net/note/delete/74263/bad+code Del: spam -- https://master.php.net/note/delete/74263/spam Del: non-english -- https://master.php.net/note/delete/74263/non-english Del: in docs -- https://master.php.net/note/delete/74263/in+docs Del: other reasons-- https://master.php.net/note/delete/74263 Reject -- https://master.php.net/note/reject/74263 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#125015) next »