Webservice call from PHP – wsdl2php makes it simple

From PHP we usually do a lot of coding to create a webservice client. We use nusoap library for this purpose. But in the case of complex objects, it is very hard to create a soap client call. We need to create a class structure before invoke a wsdl call.

php

As a solution, you can use wsdl2php converter tool. It is a command line tool, you can provide the wsdl url as an input and it generates a php file to make the soap client call. The tool may show some error during its conversion , but in the end, you will get a PHP code which executes.

Download wsdl2php from: http://www.urdalen.no/wsdl2php/

4 Comments

4 Responses to “Webservice call from PHP – wsdl2php makes it simple”

  1. Fredrik Wallgren November 24, 2009 at 4:39 am #

    Hello!

    I would like to recommend wsdl2phpgenerator(http://code.google.com/p/wsdl2phpgenerator/). It has support for PHP5.3 and can be used as a cli application or used directly in your PHP code as a code library.

  2. Sajith M.R November 10, 2010 at 7:11 pm #

    Thanks a lot for this tool. It helped me again and again. Coool

  3. Vishal Gaurav December 23, 2010 at 7:22 pm #

    Hi Sajith

    I am a beginner in PHP and was looking for a tool to convert wsdl to php files.
    I came across the wsdl2php and insatlled the same by following the steps mentioned at http://www.urdalen.no/wsdl2php/

    As per this site, it seems the installation went well without any issue. Before thsi let me mention that I had wamp intalled in my system.

    At last when I am trying to use wsdl2php in the command prompt, it says wsdl2php is not recognized as internal or external command.

    I am trying to execute it as follows:
    A:\wsdl2php .wsdl > .php

    Here A:\ = C:\Program Files\wamp\bin\php\php5.3.0\PEAR

    Is this the right place to call the command wsdl2php.

    Vishal

Leave a Reply

More in php (44 of 104 articles)


We like firebug , We like PHP , if so, We also begin to  like FirePHP !!! Using firephp , ...