|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2007-07-24 14:13 UTC] sanderovich at avaya dot com
Description: ------------ When using WSI Basic compliant wsdl, a call to functions without parameters return procedure xxx not found despite the fact that the function exist(they exist both in the wsdl and in the array returned by SoapServer::getFunctions()). Functions with parameters are being executed correctly. For example: A Soap call to : firstFunctionWithoutParam() return the following SoapFault: <?xml version="1.0" encoding="UTF-8"?> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> <SOAP-ENV:Body> <SOAP-ENV:Fault> <faultcode>SOAP-ENV:Server</faultcode> <faultstring>Procedure 'firstFunctionWithoutParam' not present </faultstring> </SOAP-ENV:Fault> </SOAP-ENV:Body> </SOAP-ENV:Envelope> despite the fact that the function exist in the return SoapServer::getFunctions() Array ( [0] => firstFunctionWithoutParam [1] => secondFunctionWithoutParam [2] => firstFunctionClassParam [3] => secondFunctionClassParam ) Soap Data (from $HTTP_RAW_POST_DATA): <?xml version="1.0" encoding="UTF-8"?> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> <SOAP-ENV:Body> <firstFunctionWithoutParam/> </SOAP-ENV:Body> </SOAP-ENV:Envelope> Soap data for Soap call with parameters: <?xml version="1.0" encoding="UTF-8"?> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> <SOAP-ENV:Body> <firstFunctionClassParam> <param>oren</param> <vectparam>one</vectparam> <vectparam>two</vectparam> </firstFunctionClassParam> </SOAP-ENV:Body> </SOAP-ENV:Envelope> Thanks for your help Reproduce code: --------------- A zip file file SoapClient\Server can be found in following link http://myfreefilehosting.com/f/bf039ff168_0.1MB PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Nov 01 07:00:01 2025 UTC |
I believe that there are here two different problems. The first is that the Soap client does not create the SoapBody correctly for a function without parameters(the SoapBody is empty), that's why my SoapClient includes the following lines: if ( $parameters == null) { $return = $itc_client->__soapCall($methodName, array(new SoapParam(null, $methodName)), null, $security_header); // $return = $itc_client->__soapCall($methodName, array(), null, $security_header); } The second problem is in the SoapServer that does recognize functions without parameters.