#29194 [Opn->Bgs]: "Amélie" turns into "Amélie" after simplexml_load_file()

From: Date: Wed, 21 Jul 2004 21:00:19 +0000
Subject: #29194 [Opn->Bgs]: "Amélie" turns into "Amélie" after simplexml_load_file()
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-63288@lists.php.net to get a copy of this message
ID: 29194 Updated by: derick@php.net Reported By: tsigo at tsigo dot org -Status: Open +Status: Bogus Bug Type: SimpleXML related Operating System: Gentoo PHP Version: 5.0.0 New Comment: 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. This is not a bug, but a feature. Previous Comments: ------------------------------------------------------------------------ [2004-07-21 21:38:28] kemps at free dot fr It's seems that the output is utf-8 encoded. I personnaly used a utf8decode($string_to_output). Don't know if it is a bug or not ! (Francois) ------------------------------------------------------------------------ [2004-07-15 23:58:12] tsigo at tsigo dot org Description: ------------ Example XML file: <?xml version="1.0" encoding="us-ascii"?> <Collection> <DVD> ... <Title>Am&#233;lie</Title> ... </DVD> </Collection> This is referring the movie "Amelie", and &#233 should turn into an accented 'e' (é), but instead it gets processed as "Amélie". Reproduce code: --------------- $Collection = simplexml_load_file($filename); echo htmlentities((string) $Collection->DVD->Title); // Produces "Am&Atilde;&copy;lie" Expected result: ---------------- Preserve the &#233; in the title. Actual result: -------------- Changes &#233; to é ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=29194&edit=1

« previous php.bugs (#63288) next »