#45035 [Opn->Bgs]: Reg exp. '/\w/u' not include ő, ű, Ő; and Ű; utf characters
| From: | nlopess@php.net | Date: | Mon, 19 May 2008 09:29:57 +0000 |
| Subject: | #45035 [Opn->Bgs]: Reg exp. '/\w/u' not include ő, ű, Ő; and Ű; utf characters | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-125112@lists.php.net to get a copy of this message | ||
ID: 45035
Updated by: nlopess@php.net
Reported By: kamarton at gmail dot com
-Status: Open
+Status: Bogus
Bug Type: PCRE related
Operating System: Win XP
PHP Version: 5.2.6
New Comment:
Not a bug in PHP. Bugs in the PCRE lib should be filled at:
http://bugs.exim.org/enter_bug.cgi?product=PCRE
Previous Comments:
------------------------------------------------------------------------
[2008-05-18 19:07:55] kamarton at gmail dot com
Reproduce code:
---------------
echo
preg_replace('/\w/u','_','öüóőúéáűíÖÜÓŐÚÉÁŰÍ');
Expected result:
----------------
echo -> '__________________'
Actual result:
--------------
echo -> '___ő___ű____Ő___Ű_'
------------------------------------------------------------------------
[2008-05-18 18:52:42] kamarton at gmail dot com
Description:
------------
The regular expression engine with 'u' modifiers '\w' class not include
few hungarian characters.
Not include: ő, ű, Ő and Ű.
PHP source file coding in utf8 with BOM.
Sorry my english.
Regards,
Marton
System:
WinXP, SP2
PHP 5.2.5 (xampp version)
(source editor: Notepad++ v4.9.2.)
Reproduce code:
---------------
echo
preg_replace('/\w/u','_','öüóőúéáűíÖÜÓŐÚÉÁŰÍ');
Expected result:
----------------
echo -> '__________________'
Actual result:
--------------
echo -> '___ő___ű____Ő___Ű_'
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=45035&edit=1