From: Rasmus Lerdorf Date: Mon, 12 Mar 2012 06:11:58 +0000 (+0000) Subject: This change was badly worded and filed in the wrong section. X-Git-Tag: PHP-5.4.1-RC1~43 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e99a8c770f6fd7601a338654161b0f942b1392c4;p=php This change was badly worded and filed in the wrong section. This isn't an ini change at all. --- diff --git a/UPGRADING b/UPGRADING index f83e7543c5..bbc5478048 100755 --- a/UPGRADING +++ b/UPGRADING @@ -36,15 +36,6 @@ PHP 5.4 UPGRADE NOTES 1. Changes to INI directives ============================= -- The default character set is now UTF-8 when the default_charset - php.ini directive is not explicitly set. This applies to functions - such as htmlentities() and htmlspecialchars(). If you were relying - on the previous default of ISO-8859-1 you will need to add: - - default_charset = iso-8859-1 - - to your php.ini to preserve pre-PHP 5.4 behavior. - - PHP 5.4 now checks at compile time if /dev/urandom or /dev/arandom are present. If either is available, session.entropy_file now defaults to that file and session.entropy_length defaults to 32. @@ -200,6 +191,13 @@ PHP 5.4 UPGRADE NOTES - call_user_func_array() no longer allows call-time pass by reference. +- the default character set for htmlspecialchars() and htmlentities() is + now UTF-8. In previous versions it was ISO-8859-1. Note that changing + your output charset via the php.ini default_charset directive does not + affect htmlspecialchars/htmlentities unless you are passing "" (an + empty string) as the encoding parameter to your htmlspecialchars/htmlentities + calls. + - htmlentities() and htmlspecialchars() are stricter in the code units they accept for the asian encodings. For Big5-HKSCS, the octets 0x80 and 0xFF are rejected. For GB2312/EUC-CN, the octets 0x8E, 0x8F, 0xA0 and 0xFF are