Closed florentpoiteau closed 11 years ago
The wsdl File :
<?xml version="1.0"?>
<definitions xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://www.kastor.com.localhost/app_dev.php/soap/return" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap-enc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" name="return" targetNamespace="http://www.kastor.com.localhost/app_dev.php/soap/return">
<portType name="returnPortType">
<operation name="getHello" parameterOrder="name">
<input message="tns:getHelloRequest"/>
<output message="tns:getHelloResponse"/>
</operation>
<operation name="goodbye" parameterOrder="name">
<input message="tns:goodbyeRequest"/>
<output message="tns:goodbyeResponse"/>
</operation>
</portType>
<binding name="returnBinding" type="tns:returnPortType">
<soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
<operation name="getHello">
<soap:operation soapAction="http://www.kastor.com.localhost/app_dev.php/soap/returngetHello"/>
<input>
<soap:body use="literal" namespace="http://www.kastor.com.localhost/app_dev.php/soap/return" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" parts="name"/>
</input>
<output>
<soap:body use="literal" namespace="http://www.kastor.com.localhost/app_dev.php/soap/return" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" parts="return"/>
</output>
</operation>
<operation name="goodbye">
<soap:operation soapAction="http://www.kastor.com.localhost/app_dev.php/soap/returngoodbye"/>
<input>
<soap:body use="literal" namespace="http://www.kastor.com.localhost/app_dev.php/soap/return" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" parts="name"/>
</input>
<output>
<soap:body use="literal" namespace="http://www.kastor.com.localhost/app_dev.php/soap/return" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" parts="return"/>
</output>
</operation>
</binding>
<service name="returnService">
<port name="returnPort" binding="tns:returnBinding">
<soap:address location="http://www.kastor.com.localhost/app_dev.php/soap/return"/>
</port>
</service>
<message name="getHelloRequest">
<part name="name" type="xsd:string"/>
</message>
<message name="getHelloResponse">
<part name="return" type="xsd:string"/>
</message>
<message name="goodbyeRequest">
<part name="name" type="xsd:string"/>
</message>
<message name="goodbyeResponse">
<part name="return" type="xsd:string"/>
</message>
</definitions>
Look in your app/logs/dev.log file for CRITICAL errors.
Thank you for your answer but my log didn't help me :
[2013-04-16 08:02:49] request.CRITICAL: SoapFault: Wrong Version (uncaught exception) at C:\Projet\src\WebService\SoapBundle\Controller\HelloServiceController.php line 36 [] []
Another idea?
There is no CRITICAL before that one? Try making your SOAP call like this: $client->hello('toto');
I tried it, but same result !
The bug is on the saop call, it stops at this line, and I tried so many solutions, I really don't understand why.
Thanks for help !
Hmm very strange. Could you try one more thing?
$client = new \Soapclient('http://localhost/app_dev.php/soap/return', array('cache_wsdl' => WSDL_CACHE_NONE));
or
$client = new \Soapclient('http://localhost/app_dev.php/soap/return?wsdl', array('cache_wsdl' => WSDL_CACHE_NONE));
Same results, I tried even with 'soap_version' => SOAP_1_2, 'soap_version' => SOAP_1_1, trace => true, exceptions => true...
Nothing more than this Wrong version !
Hi,
after some works on it, I found something :
The controller must return a response (null given). Did you forget to add a return statement somewhere in your controller?
I don't know where but ok ...
Hi,
it seems this bundle didn't support symphony 2.0.x, I tried this bundle on a symfony 2.2 server and works fine. Thanks for help. I close this issue !
Hi,
my project is on Symfony 2.0.x and I installed your bundle. I'm working on a local config.
I follow all the steps of configuration and exemple on the doc.
Like in doc, I get a wsdl (file or text) on my url http:/localhost/app_dev.php/soap/return.
The wsdl file seems ok :
Then I put a serviceController :
And the file which contains the method is :
At the end when I launch the url : http://localhost/app_dev.php/soap/hello
An error occurs : Wrong Version
I have searched for any solutions but nothing found.
Do you have any idea? Thank you.