|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2005-05-30 19:51 UTC] alex at idoia dot com
Description: ------------ the description says: "offset may be specified to begin searching an arbitrary number of characters into the string. Negative values will stop searching at an arbitrary point prior to the end of the string." And I think the right definition is: offset may be specified to begin searching an arbitrary number of characters into the string. Negative values will START searching at an arbitrary point prior to the end of the string. PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2026 The PHP GroupAll rights reserved. |
Last updated: Sat Feb 14 09:00:01 2026 UTC |
Hi Alex, Actually that's not quite correct either. Negative offset values mean the end of string is moved to the left by the magnitude of the specified value plus one. E.g. strripos('abcdef', 'b', -4) will search the string 'abc' for 'b'. I've updated the manual to be a little more explicit.