#40361 [Opn->Asn]: SOAP messages contain empty tags

From: Date: Mon, 05 Feb 2007 10:44:09 +0000
Subject: #40361 [Opn->Asn]: SOAP messages contain empty tags
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-108416@lists.php.net to get a copy of this message
ID: 40361 Updated by: tony2001@php.net Reported By: mail at martin-probst dot com -Status: Open +Status: Assigned Bug Type: SOAP related Operating System: Mac OS X PHP Version: 5.2.0 -Assigned To: +Assigned To: dmitry New Comment: Dmitry, it's expected behavior, or is it not? Previous Comments: ------------------------------------------------------------------------ [2007-02-05 09:28:07] 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> ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=40361&edit=1

« previous php.bugs (#108416) next »