Re: [PHP] nuSoap client SOAP Call problem
- From: angelo@xxxxxxxxxxxx (Angelo Zanetti)
- Date: Fri, 24 Aug 2007 13:55:29 +0200
Thijs Lensselink wrote:
On Fri, 24 Aug 2007 12:39:06 +0200, Angelo Zanetti <angelo@xxxxxxxxxxxx> wrote:
Thijs Lensselink wrote:
On Fri, 24 Aug 2007 11:53:12 +0200, Angelo Zanetti <angelo@xxxxxxxxxxxx>wrote:
method.It's probably better to ask on a NuSOAP list.
The call method needs an array with parameters as far as i remember.
But i never use the call method anyway. I always go for the send
SOAP extension?Hey Angelo,First create your request XML.'literal');
$request = '<SubscriptionStatus xmlns='http://localhost/'>
<ISPID>xx</ISPID>
<ISPPassword>yy</ISPPassword>
<ISPUserID>Angelo1</ISPUserID>
</SubscriptionStatus>';
Then serialize the envelope so it looks like a SOAP request.
$msg = $client->serializeEnvelope($request, false, false, 'document',
And use the send method to make a connection and send the request.The action variable is that the URL of the WSDL?
$action = 'location of the webservice';
$results = $client->send($msg, $action, 60, 60);Why do you have 60 twice? As far as I can see in the API the send
document is only receiving 3 parameters?
I have posted to many SOAP forums and the mailing list. No luck what so
ever. Your the first to reply thanks, I think this could work.
Your help is very much appreciated.
regards
Angelo
I know getting info for NuSOAP is a b*tch. Maybe switch to PHP5 and the
The $action variable is not the WSDL url. I missed that part in yourfirst post.
The $action var is actually build up from two parts. The first partbeing the webservice
location. And the second part is /webserviceActionsoapclient
The reason i have two 60's in the method call is because in the
class the method looks like this:{
function send($msg, $soapaction = '', $timeout=0, $response_timeout=30)
But in the meantime i've been trying some other things with NuSOAP. Andgot this to work with WSDL.
$request = '<SubscriptionStatus xmlns='http://localhost/'>Hi, yes I have done it as you have specified with the call method
<ISPID>xx</ISPID>
<ISPPassword>yy</ISPPassword>
<ISPUserID>Angelo1</ISPUserID>
</SubscriptionStatus>';
$params = array('request' => $request);
$operation = 'WebserviceAction';
$result = $client->call($operation, $params, $namespace);
Hope this helps.
unfortunately for some weird reason that creates the duplication.
However I have almost got your previous mail working. But in the XML
request I have:
Now I see this is present: xmlns:0="" --> its an error thats making the
XML invalid any reason why its making that?
<?xml version="1.0" encoding="utf-8"?>
<SOAP-ENV:Envelope
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:si="http://soapinterop.org/xsd" xmlns:0="">
Another thing i that I have made the action variable to :
"wsdlURL/SubscriptionStatus" where wsdlURL is the URL of wsdl.
This also doesnt work but it might have to do with the above invalid XML
so perhaps this is the correct way to create the action parameter?
Thanks again very much.
The empy xmlns means there is no namespace set.
I guess you didn't provide a namespace in the serializeEnvelope method.
The 3rd parameter is set to false in the example. But that's where you should set the $namspace.
The WSDL url should work if you take of the ?wsdl part.
Thanks again.
I have specified the namespace but the problem is that its creating the weird characters:
xmlns:0=""
:0 Im not sure where they come from and I'm not sure I need the name space anyway
Any idea why its causing this character?
thank
--
------------------------------------------------------------------------
Angelo Zanetti
Systems developer
------------------------------------------------------------------------
*Telephone:* +27 (021) 552 9799
*Mobile:* +27 (0) 72 441 3355
*Fax:* +27 (0) 86 681 5885
*
Web:* http://www.zlogic.co.za
*E-Mail:* angelo@xxxxxxxxxxxx <mailto:angelo@xxxxxxxxxxxx>
.
- Follow-Ups:
- Re: [PHP] nuSoap client SOAP Call problem
- From: Thijs Lensselink
- Re: [PHP] nuSoap client SOAP Call problem
- References:
- Re: [PHP] nuSoap client SOAP Call problem
- From: Angelo Zanetti
- Re: [PHP] nuSoap client SOAP Call problem
- From: Thijs Lensselink
- Re: [PHP] nuSoap client SOAP Call problem
- Prev by Date: Re: [PHP] nuSoap client SOAP Call problem
- Next by Date: Good php-news newsletter?
- Previous by thread: Re: [PHP] nuSoap client SOAP Call problem
- Next by thread: Re: [PHP] nuSoap client SOAP Call problem
- Index(es):
Relevant Pages
|