|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #48283 Invalid and wrong SOAP request using WSDL
Submitted: 2009-05-14 15:09 UTC Modified: 2009-05-22 08:16 UTC
From: vanya at myfastmail dot com Assigned:
Status: Not a bug Package: SOAP related
PHP Version: 5.2.9 OS: Kubuntu 9.04
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
Solve the problem:
17 + 10 = ?
Subscribe to this entry?

 [2009-05-14 15:09 UTC] vanya at myfastmail dot com
PHP SOAP extension produces invalid and incorrect SOAP request, see actual result. __soapCall was tried, direct ->functionName(attributes) approach tried as well.

Reproduce code:

Expected result:
No Exception thrown, SOAP request should be something like this:

<soapenv:Envelope xmlns:soapenv="" xmlns:ns="">

Actual result:
Exception from server because of wrong request, SOAP request is the following:

<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV=""
	xmlns:ns1="" xmlns:xsi=""
		<ns1:getLebenslageTree xsi:type="ns1:PrimaryKeyWs">
		<param4 xsi:type="ns1:ProfilDataWs">
			<regionIds xsi:nil="true" />
			<mandantenIds xsi:nil="true" />
			<kategorien xsi:nil="true" />
			<kategorienUndVerknuepfung />

Which is TOTALLY wrong... :(


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2009-05-14 15:48 UTC] vanya at myfastmail dot com
Ok, sorry guys, this was my fault. Service should be called like this:

    $param = new stdClass();
    $param->lebenslageKey = $pkey; 
    $param->kategorieIds = $kategorieIds; 
    $param->mandantenIds = $mandantenIds; 
    $param->operatorAnd = false; 
    $param->profilData = $profilData;
    $treeInfo = $lebenslage->__soapCall('getLebenslageTree', array($param));

and not the way I used it. But still output is strange. You can just close this bug..
 [2009-05-22 08:16 UTC] vanya at myfastmail dot com
Bogus report, sorry.
 [2013-02-24 20:02 UTC] reto at casserini dot com
Another workaround. 

Instead of

    <message name="getCourses">
        <part name="parameters" type="xsd:int"/>
    <message name="getUsers">
        <part name="parameters" type="xsd:int"/>

which always leads to a call of the first operation "getCourses", I define two new types:

    <xsd:element name="getCoursesInput" type="xsd:int"/>
    <xsd:element name="getUsersInput" type="xsd:int"/>

and use them for the messages:

    <message name="getCourses">
        <part name="parameters" element="tns:getCoursesInput"/>
    <message name="getUsers">
        <part name="parameters" element="tns:getUsersInput"/>

works fine for me.
PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Tue Jan 31 05:03:50 2023 UTC