2002-10-10 19:06:00 +00:00
|
|
|
|
--TEST--
|
2002-10-11 13:43:24 +00:00
|
|
|
|
Translit failure
|
2002-10-10 19:06:00 +00:00
|
|
|
|
--SKIPIF--
|
2002-10-11 18:07:47 +00:00
|
|
|
|
<?php
|
2002-10-29 16:28:12 +00:00
|
|
|
|
/* include('skipif.inc'); */
|
2002-10-21 10:35:02 +00:00
|
|
|
|
( ICONV_IMPL != "libiconv" ) and die("skip ICONV_IMPL != \"libiconv\"");
|
2002-10-11 18:07:47 +00:00
|
|
|
|
?>
|
2002-10-28 17:15:21 +00:00
|
|
|
|
--INI--
|
|
|
|
|
error_reporting=2039
|
2002-10-10 19:06:00 +00:00
|
|
|
|
--FILE--
|
|
|
|
|
<?php
|
2002-10-29 16:28:12 +00:00
|
|
|
|
/* include('test.inc'); */
|
2002-10-10 19:06:00 +00:00
|
|
|
|
// Should be ok.
|
|
|
|
|
// Content from file is from libiconv testkit. Tested both
|
|
|
|
|
// with a string as an implode, no difference.
|
|
|
|
|
// if at some point internal encoding changes, set correct one
|
|
|
|
|
// in INI section or use file 'TranslitFail1.ISO-8859-1'.
|
|
|
|
|
|
2002-10-11 07:38:18 +00:00
|
|
|
|
set_time_limit(5);
|
|
|
|
|
/*
|
2002-10-21 10:35:02 +00:00
|
|
|
|
* The bug (fixed in libiconv 1.8) was confirmed that iconv goes into an
|
2002-10-11 07:38:18 +00:00
|
|
|
|
* infinite loop when ASCII//TRANSLIT is performed. We should stop it in
|
|
|
|
|
* some time.
|
|
|
|
|
*/
|
|
|
|
|
|
2002-10-10 19:06:00 +00:00
|
|
|
|
$test = '<27>crit par %s.';
|
2002-10-14 23:09:48 +00:00
|
|
|
|
|
2003-07-06 21:44:44 +00:00
|
|
|
|
var_dump(iconv("ISO-8859-1", "ASCII//TRANSLIT", $test));
|
2002-10-10 19:06:00 +00:00
|
|
|
|
?>
|
|
|
|
|
--EXPECT--
|
2003-07-06 21:44:44 +00:00
|
|
|
|
string(14) "'Ecrit par %s."
|