php regex word boundary matching in utf-8

后端 未结 4 963
半阙折子戏
半阙折子戏 2020-11-27 08:30

I have the following php code in a utf-8 php file:

var_dump(setlocale(LC_CTYPE, \'de_DE.utf8\', \'German_Germany.utf-8\', \'de_DE\', \'german\'));
var_dump(m         


        
4条回答
  •  粉色の甜心
    2020-11-27 08:46

    Guess this was related to Bug #52971

    PCRE-Meta-Characters like \b \w not working with unicode strings.

    and fixed in PHP 5.3.4

    PCRE extension: Fixed bug #52971 (PCRE-Meta-Characters not working with utf-8).

提交回复
热议问题