|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2007-06-04 13:08 UTC] spam02 at pornel dot net
[2007-06-04 13:18 UTC] tony2001@php.net
[2007-08-17 03:00 UTC] vrana@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Oct 24 07:00:01 2025 UTC |
Description: ------------ preg_match() with 'u' modifier is supposed to use UTF-8, but this switch doesn't affect offset parameter, which is always in bytes. This gotcha at least deserves to be documented, although consistent unicode support would be even better. Reproduce code: --------------- <?php preg_match('/./u',urldecode('%C2%AE').'NY',$m,NULL,2); echo $m[0]; Expected result: ---------------- Y Actual result: -------------- N