note 102024 added to function.strpos

From: Date: Sun, 23 Jan 2011 23:32:03 +0000
Subject: note 102024 added to function.strpos
Groups: php.notes 
Request: Send a blank email to php-notes+get-176231@lists.php.net to get a copy of this message
Example 2 issue: Example 2 gives a value of false if the needle is found at position zero within the haystack. i.e.: $pos = strpos('str1, str2', 'str1'); if($pos !== false) { // This would give an answer of zero and so would evaluate to false which in this case would be incorrect } ---- Server IP: 69.147.83.197 Probable Submitter: 90.196.158.173 ---- Manual Page -- http://www.php.net/manual/en/function.strpos.php Edit -- https://master.php.net/note/edit/102024 Del: integrated -- https://master.php.net/note/delete/102024/integrated Del: useless -- https://master.php.net/note/delete/102024/useless Del: bad code -- https://master.php.net/note/delete/102024/bad+code Del: spam -- https://master.php.net/note/delete/102024/spam Del: non-english -- https://master.php.net/note/delete/102024/non-english Del: in docs -- https://master.php.net/note/delete/102024/in+docs Del: other reasons-- https://master.php.net/note/delete/102024 Reject -- https://master.php.net/note/reject/102024 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#176231) next »