mirror of
https://github.com/php/php-src.git
synced 2026-04-20 14:31:06 +02:00
Implements initial stage of accepted RFC to remove them: https://wiki.php.net/rfc/remove_utf8_decode_and_utf8_encode Tests relating to SOAP and htmlspecialchars seem to have been using this entirely unnecessarily, so have been fixed. Closes GH-8726.
12 lines
231 B
PHP
12 lines
231 B
PHP
--TEST--
|
|
Bug #20934 (htmlspecialchars returns latin1 from UTF-8)
|
|
--FILE--
|
|
<?php
|
|
$str = "\xc3\xa0\xc3\xa1";
|
|
echo bin2hex($str), "\n";
|
|
echo bin2hex(htmlspecialchars($str, ENT_COMPAT, "UTF-8")), "\n";
|
|
?>
|
|
--EXPECTF--
|
|
c3a0c3a1
|
|
c3a0c3a1
|