|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2012-05-06 04:35 UTC] kulakov74 at yandex dot ru
[2012-05-06 05:07 UTC] rasmus@php.net
-Status: Open
+Status: Not a bug
[2012-05-06 05:07 UTC] rasmus@php.net
[2012-05-06 06:06 UTC] kulakov74 at yandex dot ru
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Nov 30 17:00:01 2025 UTC |
Description: ------------ I want to check if a string is a single wordcharacter but even it has a trailing linebreak preg_match() returns 1. Test script: --------------- echo preg_match('~^\w$~', "a\n"); Expected result: ---------------- 0 Actual result: -------------- 1