HomePHP Page 2 - Developing SOAP Clients using PHP
Debugging NuSOAP - PHP
SOAP (Simple Object Access Protocol) provides a flexible communication layer between applications, regardless of platform and location. As long as both the server and the client speak SOAP, they can communicate. A PHP-based web application can ask a Java database application to get some information. In this article we will try to focus on different methods of developing SOAP web service clients in PHP.
Here we are creating a soapclient object to access the add web service. If there is any error during construction, we are printing this error. If there is no error, we are calling this remote method. If this method returns any fault then we are printing the result of this function along with the request and response SOAP messages, debug string as well. If there is no fault then we are trying to get the errors that occurred during the last method call. If there are any errors then we are printing these errors along with the SOAP request, response and debug string. If there is no error then we are printing the server response. Here is a demo SOAP request message.