Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 0.14.0

Bug #8086 Unable to correctly parse a WSDL
Submitted: 2006-06-30 09:39 UTC
From: simone dot m at lynx2000 dot it Assigned:
Status: Open Package: SOAP (version 0.9.4)
PHP Version: 4.4.1 OS: Linux Red Hat 9
Roadmaps: (Not assigned)    

 [2006-06-30 09:39 UTC] simone dot m at lynx2000 dot it (Simone Marchioni)
Description: ------------ I'm trying to create a SOAP client from a WSDL created with Apache Axis version: 1.2.1. When I try to create an object directly from the proxy code, PEAR:SOAP returns me the following notice: Notice: Undefined index: impl in /usr/local/php/lib/php/SOAP/WSDL.php on line 620 The the client doesn't work correctly, and I can't use the web service. Test script: --------------- require_once('SOAP/Client.php'); $client = new SOAP_WSDL(''); $proxy = $client->getProxy(); $params = array('ticketCig' => '123456'); $results = $proxy->getDatiUtenteCig($params); Expected result: ---------------- The script above should create a working object based on the WSDL, but it doesn't work. With Perl's SOAP::Lite it works correctly. Actual result: -------------- Notice: Undefined index: impl in /usr/local/php/lib/php/SOAP/WSDL.php on line 620


 [2006-09-30 11:39 UTC] rkramar at gmail dot com (Roman Kramar)
Had the same problem with Google Adwords API WSDLs (e.g. From what I see this probably happens because the WSDL file defines two namespaces having the same values: "impl" and "intf" both assigned "". Since "intf" follows "impl" in the WSDL it seems to have precedence in the resulting tree. I switched their order to "intf" first and "impl" after that and it solved the problem. But this is just a manual workaround and will not work if you rely on automatic WSDL updates.
 [2007-01-02 22:03 UTC] sean_otoole at yahoo dot com (Sean)
I'm having a similiar problem. Parsing the following WSDL file, I get "Notice: Undefined index: typens in WSDL.php on line 459". Though unlike simone, I'm still able to use the SOAP client. PHP 4.3.6, SOAP 0.9.4, OS: Windows 2000NT Test Script: $wsdl_url = ''; $WSDL = new SOAP_WSDL($wsdl_url); $client = $WSDL->getProxy(); $params = array('MYNUMBER' => $gTS); $results = $client->getMYNUMBER($params); WSDL: <?xml version="1.0" encoding="UTF-8"?> <wsdl:definitions targetNamespace="http://com/denodo/webservice/priority" xmlns:typens="http://com/denodo/webservice/priority" xmlns:wsdlns="http://com/denodo/webservice/priority" xmlns:apachesoap="" xmlns:soapenc="" xmlns:wsdl="" xmlns:wsdlsoap="" xmlns:xsd=""> <wsdl:types> <schema targetNamespace="http://com/denodo/webservice/priority" xmlns="" elementFormDefault="qualified"> <complexType name="Parameters"> <sequence> <element name="MYNUMBER" type="xsd:string" minOccurs="0"/> </sequence> </complexType> <element name="PRIORITYHTTPReturn1"> <complexType> <sequence> <element name="item" type="typens:PRIORITYHTTPReturnRow_1" nillable="true" minOccurs="0" maxOccurs="unbounded"/> </sequence> </complexType> </element> <complexType name="PRIORITYHTTPReturnRow_1"> <sequence> <element name="MYNUMBER" type="xsd:string" minOccurs="0"/> <element name="MYAMOUNT" type="xsd:string" minOccurs="0"/> <element name="OPENING" type="xsd:string" minOccurs="0"/> <element name="STATUS" type="xsd:string" minOccurs="0"/> <element name="REASON" type="xsd:string" minOccurs="0"/> <element name="MYTIME" type="xsd:string" minOccurs="0"/> <element name="MYDATE" type="xsd:string" minOccurs="0"/> </sequence> </complexType> <element name="Parameters" type="typens:Parameters"/> </schema> </wsdl:types> <wsdl:message name="getMYNUMBERRequest"> <wsdl:part name="Parameters" element="typens:Parameters"/> </wsdl:message> <wsdl:message name="getMYNUMBERResponse"> <wsdl:part name="getMYNUMBERReturn" element="typens:PRIORITYHTTPReturn1"/> </wsdl:message> <wsdl:portType name="priority"> <wsdl:operation name="getMYNUMBER" parameterOrder="Parameters"> <wsdl:input message="wsdlns:getMYNUMBERRequest" name="getMYNUMBERRequest"/> <wsdl:output message="wsdlns:getMYNUMBERResponse" name="getMYNUMBERResponse"/> </wsdl:operation> </wsdl:portType> <wsdl:binding name="prioritySoapBinding" type="wsdlns:priority"> <wsdlsoap:binding style="document" transport=""/> <wsdl:operation name="getMYNUMBER"> <wsdlsoap:operation soapAction="" style="document" /> <wsdl:input name="getMYNUMBERRequest"> <wsdlsoap:body use="literal"/> </wsdl:input> <wsdl:output name="getMYNUMBERResponse"> <wsdlsoap:body use="literal"/> </wsdl:output> </wsdl:operation> </wsdl:binding> <wsdl:service name="priorityService"> <wsdl:port name="priority" binding="wsdlns:prioritySoapBinding"> <wsdlsoap:address location=""/> </wsdl:port> </wsdl:service> </wsdl:definitions>
 [2007-01-20 01:03 UTC] yunosh (Jan Schneider)
This happens because both WSDLs assign a namespace to two namespace prefixes, e.g. xmlns:impl="" xmlns:intf="" Is this allowed at all? SOAP_WSDL only supports a one-to-one-relation at the moment.
 [2007-11-14 17:01 UTC] foolycooly (Matt Miller)
I was getting this: Number 8 String Undefined index: impl File C:\PHP\PEAR\SOAP\WSDL.php Line 678 "I switched their order to "intf" first and "impl" after that and it solved the problem." Also worked for me.