php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #40361 SOAP messages contain empty tags
Submitted: 2007-02-05 09:28 UTC Modified: 2007-02-23 01:00 UTC
Votes:1
Avg. Score:1.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: mail at martin-probst dot com Assigned: dmitry (profile)
Status: No Feedback Package: SOAP related
PHP Version: 5.2.0 OS: Mac OS X
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: mail at martin-probst dot com
New email:
PHP Version: OS:

 

 [2007-02-05 09:28 UTC] mail at martin-probst dot com
Description:
------------
When using a Web Service and passing it a PHP object that 
contains NULL fields, these fields end up as empty tags in the 
message

Reproduce code:
---------------
no easy code, but when using a web service that expects a document style message, e.g.
<foo>
  <bar>...</bar>
</foo>

And passing an object
class Foo {
  public $bar = 'hello';
  public $baz;
}

The XML created is something like:
...
<SOAP-ENV:Body>
  <message-name>
    <foo>
       <bar>Hello</bar>
       <baz/>
    </foo>
  </message-name>
</SOAP-ENV:Body>


Expected result:
----------------
The message should be:

<SOAP-ENV:Body>
  <message-name>
    <foo>
       <bar>Hello</bar>
    </foo>
  </message-name>
</SOAP-ENV:Body>

Actual result:
--------------
The message is:

<SOAP-ENV:Body>
  <message-name>
    <foo>
       <bar>Hello</bar>
       <baz/>
    </foo>
  </message-name>
</SOAP-ENV:Body>

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-02-05 10:44 UTC] tony2001@php.net
Dmitry, it's expected behavior, or is it not? 
 [2007-02-15 15:01 UTC] dmitry@php.net
Please provide full reproducable case (with WSDL file if you use it).

 [2007-02-23 01:00 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Dec 30 14:01:28 2024 UTC