help me plz..type matching not happening

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello.
I'm doing a small example of an webservice using a self-generated
using a script by Katy Coe.
i'll post the wsdl file, the request and response from client and server.
WSDL:

<?xml version="1.0"?>
<definitions name="ServiceBooks" targetNamespace="urn:ServiceBooks"
xmlns:tns="urn:ServiceBooks" xmlns:impl="urn:ServiceBooks"
xmlns:xsd1="urn:ServiceBooks"
xmlns:xsd="http://www.w3.org/2001/XMLSchema";
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/";
xmlns="http://schemas.xmlsoap.org/wsdl/";>
 <types xmlns="http://schemas.xmlsoap.org/wsdl/";>
   <schema xmlns="http://www.w3.org/2001/XMLSchema";
targetNamespace="urn:ServiceBooks">
     <complexType name="ArrayOfBook">
				<sequence>
					<element name="Book" type="tns:Book" minOccurs="0" maxOccurs="unbounded"/>
				</sequence>
			</complexType>
     <complexType name="Book">
       <sequence>
         <element name="b_title" type="xsd:string"/>
         <element name="b_author" type="xsd:string"/>
         <element name="b_isdn" type="xsd:string"/>
       </sequence>
     </complexType>
   </schema>
 </types>
 <portType name="ServiceBooksPortType">
   <operation name="getBooks">
     <input message="tns:GetBooksRequest"/>
     <output message="tns:GetBooksResponse"/>
   </operation>
 </portType>
 <binding name="ServiceBooksBinding" type="tns:ServiceBooksPortType">
   <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
   <operation name="getBooks">
     <soap:operation
soapAction="urn:ServiceBooks#ServiceBooksServer#getBooks"/>
     <input>
       <soap:body use="encoded" namespace="urn:ServiceBooks"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
     </input>
     <output>
       <soap:body parts="return" use="encoded"
namespace="urn:ServiceBooks"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
     </output>
   </operation>
 </binding>
 <message name="GetBooksRequest"/>
 <message name="GetBooksResponse">
   <part name="return" type="tns:ArrayOfBook"/>
 </message>
 <service name="ServiceBooksService">
   <port name="ServiceBooksPort" binding="tns:ServiceBooksBinding">
     <soap:address location="http://localhost/interacesso/endpoint2.php"/>
   </port>
 </service>
</definitions>


Request:
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:ns1="urn:ServiceBooks"
xmlns:xsd="http://www.w3.org/2001/XMLSchema";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/";
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/";>
<SOAP-ENV:Body>
<ns1:getBooks/>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>


Response:
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:ns1="urn:ServiceBooks"
xmlns:xsd="http://www.w3.org/2001/XMLSchema";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/";
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/";>
<SOAP-ENV:Body><ns1:getBooksResponse>
<return xsi:type="ns1:ArrayOfBook">
<Book xsi:type="ns1:Book">
	<b_title xsi:type="xsd:string">B1</b_title>
	<b_author xsi:type="xsd:string">Author1</b_author>
	<b_isdn xsi:type="xsd:string">ISDN1</b_isdn>
</Book>
<Book xsi:type="ns1:Book">
	<b_title xsi:type="xsd:string">B2</b_title>
	<b_author xsi:type="xsd:string">Author2</b_author>
	<b_isdn xsi:type="xsd:string">ISDN2</b_isdn>
</Book>
<Book xsi:type="ns1:Book">
	<b_title xsi:type="xsd:string">B3</b_title>
	<b_author xsi:type="xsd:string">Author3</b_author>
	<b_isdn xsi:type="xsd:string">ISDN3</b_isdn>
</Book>
</return>
</ns1:getBooksResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

with this, can someone explain to me why i get "Looks like we have no
XML document" ?
if someone needs more details, feel free to ask.
thanks.

--
PHP Soap Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Kernel Newbies]     [PHP Database]     [Yosemite]

  Powered by Linux