note 86811 added to function.soap-soapserver-construct
| From: | beckmanatangryox dot com at osu1 dot php dot net | Date: | Tue, 04 Nov 2008 22:01:37 +0000 |
| Subject: | note 86811 added to function.soap-soapserver-construct | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-146134@lists.php.net to get a copy of this message | ||
While others may not do what I did, I thought if my WSDL was not local and needed to be grabbed via
HTTP, I should set the $wsdl var in __construct() to NULL, and set the 'uri' value in the
additional parameters.
This does enable non-WSDL mode, which only causes problems when using complex types. Since your
complex types are not respected/imported, you get unexpected problems out the wazoo.
So if you are exposing your class via "setClass" to the SOAP server and for some reason
your "types" aren't being returned, you can do this:
<?php
$server = new SoapServer('http://soap.example.com/genwsdl.php?api');
$server->setClass('myClass'); // previously included or defined
$server->handle();
?>
This is NOT correct:
<?php
$server = new SoapServer(NULL, array('uri' => 'http://soap.example.com/genwsdl.php?api'));
?>
I sure wish someone really smart would go into a bit more detail in this documentation of the
SoapServer options, why they exist, when to use them, etc. I find the SOAP docs lacking polish.
----
Server IP: 209.41.74.194
Probable Submitter: 72.83.255.250
----
Manual Page -- http://www.php.net/manual/en/function.soap-soapserver-construct.php
Edit -- https://master.php.net/note/edit/86811
Del: integrated -- https://master.php.net/note/delete/86811/integrated
Del: useless -- https://master.php.net/note/delete/86811/useless
Del: bad code -- https://master.php.net/note/delete/86811/bad+code
Del: spam -- https://master.php.net/note/delete/86811/spam
Del: non-english -- https://master.php.net/note/delete/86811/non-english
Del: in docs -- https://master.php.net/note/delete/86811/in+docs
Del: other reasons-- https://master.php.net/note/delete/86811
Reject -- https://master.php.net/note/reject/86811
Search -- https://master.php.net/manage/user-notes.php