Search the web
Sign In
New User? Sign Up
in-phpug · Indian PHP User Group
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Hear how Yahoo! Groups has changed the lives of others. Take me there.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
nuSOAP help needed   Message List  
Reply | Forward Message #3235 of 3263 |
Hi all,
I am new to SOAP.
can you please explain why this errors are coming.
------------------------------------------------------
Warning: SoapClient::SoapClient(http://localhost/nusoap/helloworld.php)
[soapclient.soapclient]: failed to open stream: HTTP request failed!
HTTP/1.0 500 Internal Server Error in C:\xampp\htdocs\nusoap\helloclient.php
on line 4

Warning: SoapClient::SoapClient() [soapclient.soapclient]: I/O warning :
failed to load external entity "http://localhost/nusoap/helloworld.php" in
C:\xampp\htdocs\nusoap\helloclient.php on line 4

Fatal error: Uncaught SoapFault exception: [WSDL] SOAP-ERROR: Parsing WSDL:
Couldn't load from 'http://localhost/nusoap/helloworld.php' : failed to load
external entity "http://localhost/nusoap/helloworld.php" in
C:\xampp\htdocs\nusoap\helloclient.php:4 Stack trace: #0
C:\xampp\htdocs\nusoap\helloclient.php(4): SoapClient->SoapClient('
http://localhos...') #1 {main} thrown in
C:\xampp\htdocs\nusoap\helloclient.php on line 4
----------------------------------------------------------------
I am giving you the code for client below
-------------------------------------------
File: helloclient.php
<?php
require_once('lib/nusoap.php');
$client = new soapclient('http://localhost/nusoap/helloworld.php');
$return = $client->call('hello', array('bob'));
if(!$err = $client->getError()){
echo 'Result: '.$result;
} else {
echo 'Error: '.$err;
}

print_r($return);
?>
I am giving you the code for server below
------------------------------------------------
File: helloworld.php
<?php
// Pull in the NuSOAP code
require_once('lib/nusoap.php');
// Create the server instance
$server = new soap_server;
// Register the method to expose
$server->register('hello');
// Define the method as a PHP function
function hello() {
return 'Hello, ' . $name;
}
// Use the request to (try to) invoke the service
$HTTP_RAW_POST_DATA = isset($HTTP_RAW_POST_DATA) ? $HTTP_RAW_POST_DATA : '';
$server->service($HTTP_RAW_POST_DATA);
?>

Can you please guide me what should I do.

Thanks
Surajit


[Non-text portions of this message have been removed]




Fri May 29, 2009 10:48 am

chan_suro
Offline Offline
Send Email Send Email

Forward
Message #3235 of 3263 |
Expand Messages Author Sort by Date

Hi all, I am new to SOAP. can you please explain why this errors are coming. ... Warning: SoapClient::SoapClient(http://localhost/nusoap/helloworld.php) ...
Surajit Koly
chan_suro
Offline Send Email
May 29, 2009
4:02 pm

This worked perfectly fine for me, although the nusoap library conflicted with my PHP SOAP extension, so i had to disable the PHP SOAP ext. by commenting the...
Krishna Shasankar
shasankar
Offline Send Email
May 30, 2009
7:25 am

Hi Krishna, All of my problems regarding SOAP is solved now with your help. Your comment is really helpfull for me. Thanks :) Regards Surajit ...
Surajit Koly
chan_suro
Offline Send Email
Jun 1, 2009
11:48 am
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help