NuSOAP together with PHP5-SOAP

Posted by andy

Every once in a while I get to fix/add stuff from my PHP days. Today I installed php5 on a fresh Ubuntu Feisty install I need to host a NuSOAP based service API to a client. However, the Ubuntu php module comes with SOAP support built in. The PHP bundled SOAP implementation is far from complete and I guess most folks still prefer the good 'ol NuSOAP. The problem is this:

Cannot redeclare class soapclient

Both NuSOAP and PHP's SOAP use the same class name for the client implementation. Instead of uninstalling Feisty's PHP module and rolling my own I decided to simply patch the NuSOAP 0.7.2 .php file and rename the class to nusoapclient. Saves a boatload of time IMHO. Patch to NuSOAP 0.7.2
Comments

Leave a response