php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #72751 html_entity_decode table is incorrect
Submitted: 2016-08-03 22:54 UTC Modified: 2016-08-14 04:22 UTC
From: buggy at batpudding dot com Assigned:
Status: No Feedback Package: Strings related
PHP Version: 7.0.9 OS: Linux
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: buggy at batpudding dot com
New email:
PHP Version: OS:

 

 [2016-08-03 22:54 UTC] buggy at batpudding dot com
Description:
------------
---
From manual page: http://www.php.net/function.html-entity-decode
---


Test script:
---------------
print ( html_entity_decode( "´", ENT_COMPAT, 'UTF-8' ) );

Expected result:
----------------
´

Actual result:
--------------
´

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2016-08-04 04:42 UTC] requinix@php.net
-Status: Open +Status: Feedback -Package: URL related +Package: Strings related
 [2016-08-04 04:42 UTC] requinix@php.net
If that's what you're seeing then your page is using ISO 8859-1/Latin1 encoding when it should be using UTF-8.

<?php
header ( "Content-Type: text/plain; charset=utf-8" );
print ( html_entity_decode( "&acute;", ENT_COMPAT, 'UTF-8' ) );
 [2016-08-14 04:22 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Mar 29 10:01:28 2024 UTC