What is the best solution for creating a SOAP Server in PHP?
I need some advice on which library is the best choice when it comes to creating SOAP servers (and eventually SOAP clients) in PHP.
I know there is built-in functions for this, but is that really the best way to go about it?
Also, if you could attach some arguments as to why a certain library/method is the better, i'd be much delighted.
The only requirement i currently have (apart from the obvious client/server part) is that i开发者_Go百科t can generate WSDL.
Does the WSDL version really matter at all? 1.1 or 2.0 what's the real difference/benefit of using 2.0?
I would recommend looking at the Zend_Soap class of Zend Framework.
Its fairly complete and robust and has been available in the framework long enough to have most if not all of its rough spots smoothed out. Plus its part of a framework that is being actively maintained so it will continue to support new standards and any bugs that are found will be fixed.
I use PHP's built-in SoapServer class to serve requests because it's implemented in C so it's faster than any other class implemented in PHP (Zend, nusoap).
The limitation here is that SoapServer can't generate WSDL (as of May'11) so i am using Zend SOAP Autodiscovery to generate it.
I use nuSoap: http://sourceforge.net/projects/nusoap/
精彩评论