Site Admin
|
maybe __call() is depricated, but there is no relation to nusoap library we're there about. Aren't we?
|
||||||||||||
|
|
I'm not sure i understand what you're saying. Aren't they using nusoap.php?
|
||||||||||||
|
|
Ok, so the only way to work around the caching errors is to mess up all my soap calls?
$result = $client->call('hello', array('name' => 'Scott')); is a whole lot uglier than $result = $proxy->hello('Scott'); |
||||||||||||
|
|
Using NuSOAP's call() syntax, i now get this error:
Charset from HTTP Content-Type 'UTF-8' does not match encoding from XML declaration 'ISO-8859-1' |
||||||||||||
|
Site Admin
|
Why don't you correct the encoding then?
$soapclient->soap_defencoding can be set to 'UTF-8' or 'ISO-8859-1' decode_utf8 property can be true or false |
||||||||||||
|
|
I didn't know how and figured it should work. It worked with the proxy. (The proxy only generates the methods, right?)
Changing those variables doesn't help, the server still appears to send an incorrect response: [request] => POST [...] User-Agent: NuSOAP/0.7.2 (1.2) Content-Type: text/xml; charset=ISO-8859-1 SOAPAction: "" Content-Length: 469 <?xml version="1.0" encoding="ISO-8859-1"?><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/"><SOAP-ENV:Body><getUserByUsername><bla xsi:type="xsd:int">841</bla></getUserByUsername></SOAP-ENV:Body></SOAP-ENV:Envelope> [response] => HTTP/1.1 200 OK Date: Tue, 15 Aug 2006 15:38:59 GMT Server: Apache/2.0.54 (Debian GNU/Linux) mod_jk/1.2.15 mod_python/3.1.3 Python/2.3.5 PHP/5.0.5 mod_perl/1.999.21 Perl/v5.8.4 X-Powered-By: PHP/5.0.5 Connection: close Content-Type: text/xml; charset=UTF-8 <?xml version="1.0" encoding="ISO-8859-1"?> [request] => POST [...] User-Agent: NuSOAP/0.7.2 (1.2) Content-Type: text/xml; charset=UTF-8 SOAPAction: "" Content-Length: 464 <?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/"><SOAP-ENV:Body><getUserByUsername><bla xsi:type="xsd:int">841</bla></getUserByUsername></SOAP-ENV:Body></SOAP-ENV:Envelope> [response] => HTTP/1.1 200 OK Date: Tue, 15 Aug 2006 15:54:42 GMT Server: Apache/2.0.54 (Debian GNU/Linux) mod_jk/1.2.15 mod_python/3.1.3 Python/2.3.5 PHP/5.0.5 mod_perl/1.999.21 Perl/v5.8.4 X-Powered-By: PHP/5.0.5 Connection: close Content-Type: text/xml; charset=UTF-8 <?xml version="1.0" encoding="ISO-8859-1"?> |
||||||||||||
|
Site Admin
|
Sure, client has no influence on the server. Did you develop the server yourself? If it is based on nusoap.php, you may want to change enconding for the server too. |
||||||||||||||
|
|
I didn't work on the server. It turns out we use a hacked up NuSOAP server with "better error handling".. I'll try the hacked up client that i'm supposed to use.
Thanks for the help. |
||||||||||||
Last edited by CT on Wed Aug 16, 2006 2:49 am; edited 1 time in total |
Site Admin
|
if your server outputs in ISO-8859-1 and client supports ISO-8859-1, what's the problem then?
|
||||||||||||
|
|
The server uses, i assume, NuSOAP 0.6.8 which may have been modified here. It always uses HTTP charset UTF-8 and XML encoding ISO-8859-1. That's a combo NuSOAP 0.7.2 and NuSOAP 0.6.8's call functions don't like.
I've copied the possibly modified 0.6.8 client and reverted to using proxy. If it also stops working sometime then it's not my fault. |
||||||||||||
|
|
The eval error is caused by the getProxy() function choking on a client object with error message.
Check the server result before using getProxy();
|
||||||||||||||
|
getProxy For Nusoap not working |
|
||
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