php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #29999 SOAP complains about strings not being valid utf-8
Submitted: 2004-09-06 16:23 UTC Modified: 2004-09-06 17:07 UTC
From: kore at mindwipe dot org Assigned:
Status: Not a bug Package: SOAP related
PHP Version: 5.0.1 OS: linux
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: kore at mindwipe dot org
New email:
PHP Version: OS:

 

 [2004-09-06 16:23 UTC] kore at mindwipe dot org
Description:
------------
php complains about string not being valid utf-8. Now the code works with 5.0.0 compiled against libxml2-2.6.13 but not with 5.0.1. It's the function xmlCheckUTF8 (in libxml2) that returns the value causing the error message.


Reproduce code:
---------------
<?php
$client = new SoapClient("http://xml.whereisthatip.com/ip-location-service.wsdl");

$queryresult = $client->getLocationRequest("192.48.96.9");

echo "$queryresult\n";;
?>

Expected result:
----------------
US


Actual result:
--------------
Fatal error: Uncaught SoapFault exception: [SOAP-ENV:Client] SOAP-ERROR: Encoding: string '192.48.96.9' is not a valid utf-8 string in /data/www/PRO/html/pcs/test.php:5
Stack trace:
#0 /data/www/PRO/html/pcs/test.php(5): SoapClient->getLocationRequest('getLocationRequ...', Array)
#1 {main}
  thrown in /data/www/PRO/html/pcs/test.php on line 5


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-09-06 17:07 UTC] rrichards@php.net
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions. 

Thank you for your interest in PHP.

xmlCheckUTF8 is broken in libxml2-2.6.13. Either use an older version or the latest from cvs where it's been fixed.
 [2004-09-07 08:23 UTC] luis at infomed dot sld dot cu
I downgrade to libxml2-2.6.8 and OK.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Mar 28 23:01:26 2024 UTC