Problem accessing .NET webservice with php |
Site Admin
|
"doesnt work" sounds pretty unclear.
what is the actual problem? Do you get errors or what? Did you check the content of soap requests that are comming to the server side? Are they comming at all? |
||||||||||||
_________________ The PHP IDE team |
|
i did get responses in soap format, however, i solved the problem.
.NET webservices wrap all the parameters in an array called parameters. when i changed $client->call('addCustomerMobile',$params); to $client->call('addCustomerMobile',array('parameters'=>$params)); it worked. thanks nevertheless regards jkersch |
||||||||||||
|
Site Admin
|
I think it's a nusoap 'feature'.
we always wrap parameters with this "extra" array. |
||||||||||||
_________________ The PHP IDE team |
I too am stuck on the "parameters" node |
|
I have a similar problem, but the other way around: How do I actually change that "parameters" node to instead be the name of my remote method to be called?
I have a wsdl which I am not posting yet unless needed. Instead, here is a call known to work from the ws ?tester utility:
And here is all I'm able to get my nusoap code to produce:
Things I think I need to get to work (and need help on!): - how to declare my namespace without editing nusoap.php* - how to get my declared namespace into the, currently, "parameters" node like in the first example above - how to get the "parameters" node to instead be the name of the method called, namely, "findPeoplePrivileged"? * side note: the line xmlns:tns="http://beans.ejb.ldap.brazos/" on this particular run was modified at runtime while stepping thru the debugger (awesome IDE) |
||||||||||||||||
|
Site Admin
|
probably you need to put findPeoplePrivileged into tns namespace.
|
||||||||||||
_________________ The PHP IDE team |
|
That's what I think, too, but I honestly can't seem to crack it.. Can you point me to more examples of how to configure the paramters of nusoap construction/call?
|
||||||||||||
|
Site Admin
|
When nusoap creates SOAP-ENV, it walks through WSDL provided. Probably you have a malformed or incomplete wsdl.
You may try nusoap samples for the server side and check WSDL that nusoap 'likes' |
||||||||||||
_________________ The PHP IDE team |
wsdl is fine.. can't format client request |
|
dmitri-
the wsdl is fine (posted below for inspection). What I lack is a better understanding of what parameters must be used to instruct nusoap to generate the client request that my web service requires. I'm certain it must be a trivial solution. Also, I am not 100% confident my own find/replace mentioned above to work around the naming conflict with "soap" in php5 is not perhaps interfering-- hence the request for an official dmitri-released nusoap.php. Do I need to mess with anything within nusoap.php, or is everything I need to do available via instantiation parameters? thanks! -bronius
|
||||||||||||||
|
|
ah-- nusoap is not a nusphere product.. I will take my questions elsewhere more appropriate-- sorry for the confusion.
(but if you happen to have any solutions to my Q, by all means, I'm all ears!) |
||||||||||||
|
getting somewhere! |
|
Ok (posting for the general public's knowledge), I'm getting somewhere now. Now, my client request is generating a properly formed xml document with the web service method's name being the request element name and the "arg0" arguments replacing the "<parameter />" tag. The issue (thus far) was that the wizard-generated client request code didn't clue me in to separating the wsdl from the web service server/url:
The first param is the web service server, the "true" says, "Yes, I'm passing in a wsdl," and the third param is the url of the wsdl. Before, all I sent as params was the wsdl url as guided by the wizard. hth |
||||||||||||||
|
getting nusoap.php classes to work with JAX-WS in php5 |
|
Ok, I got my web service to work in php5 (requiring renaming of "soapclient" in nusoap.php to "soapclientPE" (my chosen name)) in order to consume a typical, well-formed web service as produced by JAX-WS. There was one ticky trick, and that was that for some reason, my "endpoint" (first param in class instantiation) required a trailing query that was neither ?wsdl nor ?tester (both of which, in my case at least) are reserved for other functionality. However, without that trailing "?" and either nothing or any string not wsdl nor tester, the call would hang (and probably timeout, but I am impatient).
What I lacked before was: a "?" or "?something" trailing my "endpoint" (whereas before, I was trying to pass in the wsdl url itself) passing in the required namespace in the call to $mysoap->call() quotes around the name "arg0" in list of arguments/parameters hope this helps someone -bronius |
||||||||||||||
|
Problem accessing .NET webservice with php |
|
||
Content © NuSphere Corp., PHP IDE team
Powered by phpBB © phpBB Group, Design by phpBBStyles.com | Styles Database.
Powered by
Powered by phpBB © phpBB Group, Design by phpBBStyles.com | Styles Database.
Powered by