Edit report at http://bugs.php.net/bug.php?id=42290&edit=1
ID: 42290
Comment by: gevorg dot ha at gmail dot com
Reported by: arysin at gmail dot com
Summary: mb_eregi_replace() is not case-insensitive with
multibyte pattern
Status: Assigned
Type: Bug
Package: mbstring related
Operating System: *
PHP Version: 5.2CVS-2007-08-14
Assigned To: hirokawa
Block user comment: N
New Comment:
Hi,
please find code snippet which shoes that it doesn't work:
mb_internal_encoding("UTF-8");
mb_regex_encoding("UTF-8");
// Text contains three words with same letters, only with some
uppercases.
$hText = 'ÕÔ±Õ
Ô±ÕÕÔ±ÕÔ¸ ÕÕ¡ÕµÕ¡Õ½Õ¿Õ¡Õ¶ Õ°Õ¡ÕµÕ¡Õ½Õ¿Õ¡Õ¶';
// None of these two is working and only the last word is being
replaced.
echo mb_eregi_replace ('Õ°Õ¡ÕµÕ¡Õ½Õ¿Õ¡Õ¶', '<strong>\\0</strong>',
$hText).'<br/>';
echo mb_ereg_replace ('Õ°Õ¡ÕµÕ¡Õ½Õ¿Õ¡Õ¶', '<strong>\\0</strong>',
$hText,
'msri').'<br/>';
Best,
Gevorg
Previous Comments:
------------------------------------------------------------------------
[2010-08-28 03:20:07] [email protected]
Could you show me the detailed information such as,
- code snippet which can reproduce the problem.
- setting information of mbstring.* in php.ini
- character encoding which you are using.
- version/locale of your OS.
------------------------------------------------------------------------
[2010-08-27 16:36:18] bubalula at gmail dot com
I tried also on another server with php version 5.2.11 and it does not
work either.
------------------------------------------------------------------------
[2010-08-27 16:22:05] bubalula at gmail dot com
I have the same problem in version 5.2.12.
I don't know why this bug isn't taken seriously as it creates big
problems for us working with non latin languages.
------------------------------------------------------------------------
[2009-09-30 13:12:10] babson at gmail dot com
I am using PHP version 5.2.9 and have the same problem.
I tried sample by arysin and got the same result as he did.
What can be done?
------------------------------------------------------------------------
[2009-04-15 16:04:55] rvorojbit at gmail dot com
I am also having the exact same problem now as was described in the
previous post last year!!! Is there any workaround for this bug? I
didn't find any in google...
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/bug.php?id=42290
--
Edit this bug report at http://bugs.php.net/bug.php?id=42290&edit=1