ID:               29988
 Updated by:       [EMAIL PROTECTED]
 Reported By:      lehphyro at yahoo dot com dot br
-Status:           Open
+Status:           Bogus
 Bug Type:         SimpleXML related
 Operating System: Windows
 PHP Version:      5.0.1
 New Comment:

Not a bug, SimpleXML always converts to utf-8 internally. (Like any XML
extension in PHP).


Previous Comments:
------------------------------------------------------------------------

[2004-09-05 17:17:45] lehphyro at yahoo dot com dot br

Description:
------------
I tried to load a xml file with ISO-8859-1 encoding.

I have tried several ways for loading, but I had no success because
simplexml returns the loaded string with errors.

I have tried iconv functions too.

Reproduce code:
---------------
file test.php:
<?php
include ("example.php");

$xml = simplexml_load_string($xmlstr);

echo $xml->movie[0]->plot;
?>

file example.php:
<?php
$xmlstr = <<<XML
<?xml version='1.0' encoding="ISO-8859-1"?>
<movies>
 <movie>
  <plot>
   Matrícula
  </plot>
 </movie>
</movies>
XML;
?>

Expected result:
----------------
Matrícula

Actual result:
--------------
Matrícula


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=29988&edit=1

Reply via email to