php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #31880 SoapClient complains about string with umlauts.
Submitted: 2005-02-08 10:39 UTC Modified: 2005-02-10 10:27 UTC
From: tschlottke at virtualminds dot de Assigned:
Status: Not a bug Package: SOAP related
PHP Version: 5.0.3 OS: linux
Private report: No CVE-ID: None
 [2005-02-08 10:39 UTC] tschlottke at virtualminds dot de
Description:
------------
When I try to call a Soap-Method via SoapClient with any umlaut-containing string, soapclient complains that the string is not a valid utf8-encoded string.

It seems to differ from #29999,
which was a problem of libxml2.
I've upgraded libxml2 to cvs, the problem described in #29999 is fixed in my libxml2 so I think this should be a PHP-issue.

Reproduce code:
---------------
<?php
$client = new
SoapClient(...);

$client->anyMethod("Benutzer hinzuf?gen");

?>



Actual result:
--------------
Uncaught SoapFault exception: 
[SOAP-ENV:Client] SOAP-ERROR: Encoding: string 'Recht hinzuf?gen' is not a valid utf-8 string in /var/www/adition_gui/includes/classes/rpc.class.php:29 Stack trace: #0

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-02-08 22:32 UTC] johannes@php.net
Are you sure you're using UTF-8? Try if utf8_encode()ing 
the name of the method as proposed in the Exception. 
 [2005-02-09 09:28 UTC] tschlottke at virtualminds dot de
Uhm, shouldn't this be done transparently by ext/soap like in every SOAP-Class I've used so far?
They all encode transparently on client-side and decode on server side. Or is this just working correctly in wsdl-mode?
If I am wrong, just mark as bogus and I'll find another way workin' around this.
 [2005-02-10 10:27 UTC] johannes@php.net
No it doesn't do "transparent guessing" which encoding 
you've used. 
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Apr 24 03:01:29 2024 UTC