 |
|
|
| View previous topic :: View next topic |
| Author |
Message |
rav_nan
Joined: 21 Aug 2007 Posts: 3
|
Posted: Fri Aug 31, 2007 1:54 pm Post subject: problem running client code in webservice |
|
|
hey guys can any body help me in this code and please tell me where am i going wrong. i hav created a webservice which gives me a wsdl file as http://localhost/PhpPrograms/server.php?wsdl but cannot run the client code why? please do tell me as soon as possible. thanks in advance
<?php
require_once 'SOAP/Client.php';
// Modify the URL here - note the "?wsdl" at the end
$wsdl = new SOAP_WSDL ('http://localhost/PhpPrograms/server.php?wsdl');
$helloClient = $wsdl->getProxy();
echo ($helloClient->sayHello('Bill'));
?>
it gives me the following error
Catchable fatal error: Object of class SOAP_Fault could not be converted to string in C:\xampp\eclipse\workspace\PhpPrograms\client.php on line 9 |
|
| Back to top |
|
 |
mark

Joined: 07 Jan 2007 Posts: 1048
|
Posted: Fri Aug 31, 2007 4:54 pm Post subject: |
|
|
| sayHello() seems to return a Soap_Fault object and not a string. The docs should tell you how you can check properly for errors. |
|
| Back to top |
|
 |
rav_nan
Joined: 21 Aug 2007 Posts: 3
|
Posted: Sat Sep 01, 2007 9:24 am Post subject: |
|
|
| mark wrote: | | sayHello() seems to return a Soap_Fault object and not a string. The docs should tell you how you can check properly for errors. |
yes i have solved the problem, the problem was my Fault file in soap directory was corrupt. i changed it with a new soap directory. it started working |
|
| Back to top |
|
 |
ely_pear
Joined: 02 Oct 2007 Posts: 3
|
Posted: Tue Oct 02, 2007 5:27 pm Post subject: |
|
|
Hi,
where did you get the "safe" Fault.php from? I'm experiencing problems with PEAR :
SOAP_Fault Object
but my parameters are correct - from an on-line web service client passing the same parameter the service answers correctly.
thanks in advance |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|