php-src/tests/lang/bug24783.phpt
Antony Dovgal 8f98226510 fix tests
2006-12-06 13:11:02 +00:00

14 lines
320 B
PHP

--TEST--
Bug #24783 ($key not binary safe in "foreach($arr as $key => $val)")
--FILE--
<?php
error_reporting(E_ALL);
$arr = array (b"foo\0bar" => b"foo\0bar");
foreach ($arr as $key => $val) {
echo strlen($key), ': ';
echo urlencode($key), ' => ', urlencode($val), "\n";
}
?>
--EXPECT--
7: foo%00bar => foo%00bar