I am using nusoap library to connect to Kintera API. It worked fine on my other sites, but this one was giving me the following error message:
Fatal error: Uncaught SoapFault exception: [Client] SoapClient::SoapClient() [<a href='soapclient.soapclient'>soapclient.soapclient</a>]: Invalid parameters in /test.php:147 Stack trace: #0 /test.php(147): SoapClient->SoapClient(‘KinteraConnect….’, true) #1 {main} thrown in /test.php on line 147
Line 147 has the following code:
$client = new soapclient($wsdl,true);
After reading up online a bit, it seems this error appears on PHP 5 servers because of class name conflicts. So I opened up nusoap.php file and figured that you could just use nusoap_client as a class name. Code piece from nusoap.php
if (!extension_loaded('soap')) {
/*** For backwards compatiblity, define soapclient unless the PHP SOAP extension is loaded.*/
class soapclient extends nusoap_client {
}
}
So I just went ahead and changed
$client = new soapclient($wsdl,true);
to
$client = new nusoap_client($wsdl,true);
and it fixed it.
Good job! This helped me out.
That was really helpfull. Solved my problem, although running into the next one ;-)
Thank you thank you, a thousand times. I looked everything but found nothing until your post.
Thanks, it really helped a lot. Some existing applications have the old version of nusoap.php that doesn't have the snippet code you paste there. Don't forget to download updated nusoap files from their project page.
You are nice! Thank you!
Yes you are right dude.... I also followed your procedure and got success. Good work :)
Thanks, for your help.
hi tanya, thanks! i was having the same trouble and your page was the first result in my search!! good point!
sorry, post again because your contact section isn't available. i want to know if maybe you have a tutorial about web services, because i want know more about this subject (for example, create my own web service with autentification) because the tutorials that i has seeing only create the web service and communicate with the client without autentification. Thanks a lot again
Thanks! I spent too much time on this and your suggestion fixed it in seconds.
Thanks!
thanx!!! had the same problem and fixed it thanx to this article!!
Thanks! it helped.
I was trying to use the nusoap but got the same error. I just changed the class name just like you did and it solved my problem.
Thanks.
Hey,thankx a lot for this tip. it helped me from going through extra hassle. :)
thank you so much, your help is appriciated.
You save my day with your post! thanx!
thanks so much really appreciated
Thankq so much.. Its a great post!!
Thank you! After hours of desperation this information did save the day!