Solved

Dataset Web service and consume with nusoap issue how does one access data?

Posted on 2004-10-14
5
848 Views
Last Modified: 2008-01-09
Ok my problem is I am trying to return a dataset from a web service to a nusoap and php.  Is this possible I believe it tranforms it to some xml format correct? If so how would I access the data. I have a funny feeling I am missing something here please help.

<?php

include('nusoap.php');


$parameters = array('strCouponCode' => '1100.13', 'strGenericID' => '123456', 'strUsername' => '23', 'strPassword' => '5');

$soap = new soapclient('http://10.10.3.34/FardemptionNET/FardemptionNET.asmx?wsdl');

$result = $soap->call('getUserCouponTotalPaid',$parameters);

$acount = count($result);

print_r($result);

This is the error message i recieve back:
Array ( [faultcode] => soap:Client [faultstring] => Server did not recognize the value of HTTP Header SOAPAction: . [detail] => ) 3
0
Comment
Question by:hdemetrio
  • 2
5 Comments
 
LVL 1

Expert Comment

by:jaguarul
Comment Utility
I'm not 100% sure, but can't you call methods on the returned soap object instead of using the "call" method? something like $soap->getUserCouponTotalPaid($parameters); (maybe unfold the parameters array). It seems the SOAP package does not speecifiy the SOAPAction field in the packet, and therefore the server doesn't know what method is called.
0
 

Author Comment

by:hdemetrio
Comment Utility
I got it lol seems you need to pass the namespace of the web service and make sure its a assocative array $parameters[] = array('strCouponCode' => '1100.13', 'strGenericID' => '123456', 'strUsername' => '23', 'strPassword' => '5');  forgot the [] lol

and you need
$namespace = "www.imadumbidiotlol.com'

$soap = new soapclient('http://10.10.3.34/FardemptionNET/FardemptionNET.asmx?wsdl', $namspace);

ohh well how does that work if I answer my own question lol.
0
 
LVL 1

Expert Comment

by:jaguarul
Comment Utility
i guess you take the points :))
0
 

Accepted Solution

by:
modulo earned 0 total points
Comment Utility
PAQed, with points refunded (125)

modulo
Community Support Moderator
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
Although it can be difficult to imagine, someday your child will have a career of his or her own. He or she will likely start a family, buy a home and start having their own children. So, while being a kid is still extremely important, it’s also …
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now