ID:               30851
 Updated by:       [EMAIL PROTECTED]
 Reported By:      ibar at 163 dot com
 Status:           Bogus
 Bug Type:         Regexps related
 Operating System: RH9
 PHP Version:      4.3.9
 New Comment:

You can also just use str_replace() here...


Previous Comments:
------------------------------------------------------------------------

[2004-11-21 08:59:13] [EMAIL PROTECTED]

You need to enable mbstring extension first.
http://php.net/mbstring

------------------------------------------------------------------------

[2004-11-21 08:52:58] ibar at 163 dot com

Call to undefined function: mb_eregi_replace() 

How to use mb_eregi_replace ?

------------------------------------------------------------------------

[2004-11-21 08:32:24] [EMAIL PROTECTED]

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

POSIX regexps doesn't support multibyte symbols.
You should use mb_eregi_replace() instead.

------------------------------------------------------------------------

[2004-11-20 15:57:20] ibar at 163 dot com

Description:
------------
When I use the eregi_replace function, I can't replace the traditional
chinese letter "4" with the simplified chinese letter "4". But the
str_replace function can do.

Can you tell me which function can be used to complete it?

PS: the tradional chinese letter "4"'s specific character
is 0xA57C. But the problem appeared when replaced to the letter "7C" .

Reproduce code:
---------------
$Strings="i am ¥| ^o^";
print eregi_replace("¥|","4",$Strings);

Expected result:
----------------
i am 4 ^o^

Actual result:
--------------
Warning: ereg_replace(): REG_EMPTY in /home/site/math.php on line 9


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=30851&edit=1

Reply via email to