473,402 Members | 2,064 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,402 software developers and data experts.

Simple Nusoap Problem

Hello. I am having what is probably the simplest problem there is with
Nusoap. I have to admit I'm new to this stuff, but I have some
programming experience and what I'm doing *shouldn't* be hard. First
thing I tested the Hello (sample server and client) that are in the
Readme file. No problem. Then I tried to accepting the data from the
URL string (GET). That worked. Then I tried two parameters and the
only output I get is the word "Array". I've tried it with two
completely different scripts. I've tried all kinds of ways of loading
the arrays, and I tried echoing the array values in the client script
just to be sure they are there and they are. I'm sure I have the
latest version of nusoap.php. I searched the newsgroups for anyone
with a similar problem and couldn't find it. Any clues you could
provide would be greatly appreciated. Here's the script I'm using.

<?php

require_once('nusoap.php');
$parameters = array('name1'=>$_GET['name1'], 'name2'=>$_GET['name2]);
$soapclient = new soapclient('http://www.myserver.net/soapserverhello.php');
echo $soapclient->call('hello', $parameters);

?>

Thank you.
-Larry.
Jul 17 '05 #1
2 5250
hi larry,

the soap client is looking fine.

please make sure that the method of the soap server is taking more then one parameter.

require_once "nusoap.php";

function hello($arg1, $arg2)

{

$res = $arg1 . $arg2;

return $res;

}

$soap = new soap_server;

$soap->register("args");

$soap->service($HTTP_RAW_POST_DATA);
cheers,
moe.

<?php

require_once('nusoap.php');
$parameters = array('name1'=>$_GET['name1'], 'name2'=>$_GET['name2]);
$soapclient = new soapclient('http://www.myserver.net/soapserverhello.php');
echo $soapclient->call('hello', $parameters);

?>

Jul 17 '05 #2
Thanks. I did include two arguments to the function. I even commented
out the faults. Here's what I have. I swear this is the toughest time
I've had with a simple program.

<?php

require_once('nusoap.php');
function hello($name1, $name2){
// optionally catch an error and return a fault
/*if($name1 == ''){
return new soap_fault('Client','','Must supply a valid name.');
}
if($name2 == ''){
return new soap_fault('Client','','Must supply a valid name.');
}*/
$res_str = "hello " . $name1 . " " . $name2;
return $res_str;
}

$s = new soap_server;
$s->register('hello');
$s->service($HTTP_RAW_POST_DATA);

?>
Timo Schäfer <ti***********@media-art.net> wrote in message news:<c1*************@news.t-online.com>...
hi larry,

the soap client is looking fine.

please make sure that the method of the soap server is taking more then one parameter.

require_once "nusoap.php";

function hello($arg1, $arg2)

{

$res = $arg1 . $arg2;

return $res;

}

$soap = new soap_server;

$soap->register("args");

$soap->service($HTTP_RAW_POST_DATA);
cheers,
moe.

<?php

require_once('nusoap.php');
$parameters = array('name1'=>$_GET['name1'], 'name2'=>$_GET['name2]);
$soapclient = new soapclient('http://www.myserver.net/soapserverhello.php');
echo $soapclient->call('hello', $parameters);

?>

Jul 17 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Unbreakable | last post by:
I am using the nusoap client and nusoap server without any problem. However, once I change the client to the excel, I am not sure how to call the nusoap server. Especially the nusoap server only...
0
by: Ward G | last post by:
Hi, Below is a basic webservice using the NuSOAP class. When I run the code to register the service, I get the nice html page generated by nusoap, offering a link to view the WSDL for my...
5
by: Mark C | last post by:
I have a memory allocation problem in PHP using NuSOAP and the built in XML parser. The code below is called in a loop and executed about 1900 times before it failed. I am using nusoap.php,v 1.76...
0
by: Afnan Zari | last post by:
Hi, i've facing a problem in nusoap server ... scenario is my server is in NUSoap ... and have used complex types in my WS. My client is Pear Soap and GSoap. NuSoap ws accepts an argument...
3
by: James Kennedy | last post by:
Hi, I've downloaded the NuSoap class files. I've put them onto my localhost/ where I run my php scripts, just put the nusoap.php file in there. I've got loads of different scripts to try out...
2
by: Johnny | last post by:
Searched on google for any info relating to this before posting here but found none. I set up a web service using nusoap on apache php 4.3.8 on windows with error_reporting = E_ALL and had that...
2
by: Gary Townsend | last post by:
I am writing an app in vb .net that will use an XML webservice written in PHP NuSoap. I want to have the NuSoap server send a dataset to my VB .NET application i am trying to find any documentation...
0
by: devthx | last post by:
Hi! I code php with nusoap for my web services and would like to consume it with c# soap client. Everything seem to be fine until I try to send data in Thai characters and recieved a garbage. Does...
6
amine
by: amine | last post by:
Hello People, I created a WebService in .NET on my machine with following methode: <WebMethod(Description:="test")> _ Public Function sayHello(ByVal myName As String, ByVal myID As Integer)...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.