Herong's Tutorial Notes on Web Service and SOAP
Dr. Herong Yang, Version 2.11

SOAP PHP Implementations

This chapter describes:

  • PHP Implementations of SOAP.
  • Checking My PHP Installation on Windows.
  • Installing SOAP Library on Windows.

PHP Implementations of SOAP

If you search the Web with the key words "PHP Implementation of SOAP", you will find two popular implementations:

  • PEAR::Package::SOAP at http://pear.php.net/package/SOAP. Current release: 2005-05-31 - Version 0.9.1 (beta).
  • NuSOAP - SOAP Toolkit for PHP at http://sourceforge.net/projects/nusoap/. Current release: August 4, 2005 - Version 0.7.2.

Unfortunately, I could not find a clear feature list of the current release of PEAR::Package::SOAP.

I could not find a clear feature list of the current release of NuSOAP.

Checking My PHP Installation on Windows

Since I have PHP installed on my Windows system, I want to see if I have SOAP implementation included or not. I used the phpinfo() function to do this:

>type PhpInfo.php
   <?php phpinfo();?>

>php PhpInfo.php > PhpInfo.txt

>find /? "soap" PhpInfo.txt
---------- PHPINFO.TXT

>php -v
PHP 5.0.4 (cli) (built: Mar 31 2005 02:45:48)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v2.0.4-dev, Copyright (c) 1998-2004 Zend Technologies

So no SOAP is available in my installation, which is PHP 5.0.4 by The PHP Group.

Installing SOAP Library on Windows

Checking my PHP package to see if I have SOAP library file on my system:

>dir \php\ext\php_soap.dll

03/31/2005  02:52 AM           217,146 php_soap.dll

Cool. I do have the SOAP libary file. No need to download it from the Internet. The next thing I have to do is to make it available to the run time environment by editing \php\php.ini and insert the following line:


Now check again:

>php PhpInfo.php > PhpInfo.txt

>find /? "soap" PhpInfo.txt
---------- PHPINFO.TXT
Soap Client => enabled
Soap Server => enabled
soap.wsdl_cache_dir => /tmp => /tmp
soap.wsdl_cache_enabled => 1 => 1
soap.wsdl_cache_ttl => 86400 => 86400

Ok. I think my system is ready to run SOAP functions now.

The next question is what SOAP implementation is this php_soap.dll. Is it PEAR SOAP, NuSOAP, or something else? To check this out, I right-mouse clicked on the file \php\ext\php_soap.dll, and selected Properties. The pop up window told me this:

Internal Name: php_soap.dll
File Version:
Copyright (c) 1997-2004 The PHP Group

So the php_soap.dll is another PHP implementation of SOAP. Let's call it the PHP Group SOAP. I then browsed the installed documentation at \php\html\ref.soap.html, and got this:

SOAP Functions


The SOAP extension can be used to write SOAP Servers and Clients. It supports subsets of SOAP 1.1, SOAP 1.2 and WSDL 1.1 specifications.


There seems to be 3 popular PHP implementations of SOAP: PEAR SOAP, NuSOAP, and PHP Group SOAP. But I can not find any high level specifications for any of them.

The PHP Group SOAP 5.0.4 seems to be supporting SOAP 1.2.

Dr. Herong Yang, updated in 2006
Herong's Tutorial Notes on Web Service and SOAP - SOAP PHP Implementations