|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #29194 "Amélie" turns into "Amélie" after simplexml_load_file()
Submitted: 2004-07-15 23:58 UTC Modified: 2004-07-21 23:00 UTC
Avg. Score:2.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: tsigo at tsigo dot org Assigned:
Status: Not a bug Package: SimpleXML related
PHP Version: 5.0.0 OS: Gentoo
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
Solve the problem:
27 + 29 = ?
Subscribe to this entry?

 [2004-07-15 23:58 UTC] tsigo at tsigo dot org
Example XML file:

<?xml version="1.0" encoding="us-ascii"?>

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 é


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2004-07-21 21:38 UTC] 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-21 23:00 UTC]
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 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.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed May 22 08:01:33 2024 UTC