|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #54517 word boundary \b fails with Scandinavian alphabet
Submitted: 2011-04-12 21:19 UTC Modified: 2011-04-13 10:40 UTC
From: antti dot nylund at gmail dot com Assigned:
Status: Not a bug Package: Regexps related
PHP Version: 5.3.6 OS: Linux
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: antti dot nylund at gmail dot com
New email:
PHP Version: OS:


 [2011-04-12 21:19 UTC] antti dot nylund at gmail dot com
From manual page:
Word preceding ö ä or å will not be matched/counted.
Tried setting local with setlocale(LC_ALL, "fi_FI");

Test script:
$teststring = "Talvivaate on talvikäyttöön ja kesävaate on kesäkäyttöön.";
$rows = count($keywords[0],0);
echo $rows;

Expected result:
Should print 2

Actual result:
Prints out 1


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2011-04-13 10:40 UTC]
-Status: Open +Status: Bogus
 [2011-04-13 10:40 UTC]
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.

Prints 0 with the u flag, as expected since at least 5.3.4 when the PCRE_UCP started being used when u is present.
PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Tue Dec 05 15:01:28 2023 UTC