php-src/ext/standard/tests/strings/htmlentities04.phpt

22 lines
548 B
Plaintext
Raw Normal View History

2002-10-24 21:11:41 +00:00
--TEST--
htmlentities() test 4 (setlocale / ja_JP.EUC-JP)
--SKIPIF--
2002-11-06 15:06:35 +00:00
<?php
$result = (bool)setlocale(LC_CTYPE, "ja_JP.EUC-JP", "ja_JP.eucJP");
if (!$result || preg_match('/EUC[^a-zA-Z]*JP/i', setlocale(LC_CTYPE, 0)) == 0) {
2002-11-06 15:06:35 +00:00
die("skip setlocale() failed\n");
}
echo "warn possibly braindead libc\n";
2002-11-06 15:06:35 +00:00
?>
2002-10-24 21:11:41 +00:00
--INI--
2002-11-03 08:37:59 +00:00
output_handler=
default_charset=
mbstring.internal_encoding=none
2002-10-24 21:11:41 +00:00
--FILE--
<?php
2002-10-27 17:07:26 +00:00
setlocale( LC_CTYPE, "ja_JP.EUC-JP", "ja_JP.eucJP" );
2002-10-24 21:11:41 +00:00
var_dump(htmlentities("\xa1\xa2\xa1\xa3\xa1\xa4", ENT_QUOTES, ''));
?>
--EXPECT--
string(6) "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"