php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #31948 __soapCall & __call producing wrong output
Submitted: 2005-02-13 02:41 UTC Modified: 2005-03-01 01:00 UTC
Votes:7
Avg. Score:5.0 ± 0.0
Reproduced:5 of 5 (100.0%)
Same Version:1 (20.0%)
Same OS:3 (60.0%)
From: wico at cnh dot nl Assigned:
Status: No Feedback Package: SOAP related
PHP Version: 5.0.3 OS: debian (dotdeb php5)
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: wico at cnh dot nl
New email:
PHP Version: OS:

 

 [2005-02-13 02:41 UTC] wico at cnh dot nl
Description:
------------
$data = new soapParam('test1', 'data1');
$data = new soapParam('test2', 'data2');
$data = new soapParam('test3', 'data3');

// works correctly:
$soap->function($data); 

// outputs:
<function>
	<test1>data</test1>
	<test2>data</test2>
	<test3>data</test3>		
</function>


// produces wrong output
$soap->__call('function', $data); 
$soap->__soapCall('function', $data); 

// outputs:
<function />
<test2>data</test2>
<test3>data</test3>		

in short it closes the function tag right away but continues with putting the arguments in the xml (after removing the first argument)



Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-02-21 23:20 UTC] tony2001@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves. 

A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external 
resources such as databases, etc.

If possible, make the script source available online and provide
an URL to it here. Try to avoid embedding huge scripts into the report.

Please supply *complete* reproduce code and don't forget about expected & actual results.
 [2005-03-01 01:00 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
 [2005-06-15 14:43 UTC] dolecek at stringdata dot cz
I have very similar problem, using WSDL mode and document/literal. I have a method 'ping' with single parameter 'message', called like this :

$c = new SoapClient('my.wsdl');
$ret = $c->__soapCall('ping', array('message' => 'test'));

This sends to server this SOAP message:

<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="urn:EARCHIV"><SOAP-ENV:Body><ns1:ping/></SOAP-ENV:Body></SOAP-ENV:Envelope>

Note the 'message' parameter is completely ignored
and not included in the output. Using $c->ping(array('message' => 'test')) works, but I need
__soapCall() in order to be able to send request
headers.

I can provide the WSDL file upon request.
 [2007-06-28 09:38 UTC] s dot rabot at agematis dot com
I have the same problem that "dolecek at stringdata dot cz", the first occurence of the array given as parameter of the Soapcall method isn't send in the request.
 [2008-12-09 15:44 UTC] dontwantto at gmail dot com
I am having the same issue mentioned above.
 [2009-06-12 09:44 UTC] tomasm2005 at gmail dot com
I have found a workaround for this:
You can give the parameter as

$ret = $c->__soapCall('ping', array('parameters'=>array('message' => 'test')));

That worked for me.
 [2009-10-28 09:43 UTC] mariusz at tulikowski dot eu
I've got the same problem as users above. First variable passed in arguments section is ignored.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Apr 24 17:01:30 2024 UTC