Doc #78417 [Opn->Csd]: Description of strpos

From: Date: Tue, 23 Feb 2021 12:52:49 +0000
Subject: Doc #78417 [Opn->Csd]: Description of strpos
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-18588@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=78417&edit=1 ID: 78417 Updated by: cmb@php.net Reported by: vlada at skrbek dot cz Summary: Description of strpos -Status: Open +Status: Closed Type: Documentation Problem Package: Documentation problem PHP Version: Irrelevant -Assigned To: +Assigned To: cmb Block user comment: N Private report: N New Comment: This has been fixed in the meantime. Previous Comments: ------------------------------------------------------------------------ [2019-08-15 14:16:15] vlada at skrbek dot cz Description: ------------ --- From manual page: https://php.net/function.strpos --- Hello It is just a mine oppinion but I think to the description of strpos should be added the return value BOOLEAN not only INT because the return value is either INT if the string is found or BOOLEAN if the string is not find. I like these documentations. Also note. When I search comparator == or === it is not found. Could you fix it? Best Regards Test script: --------------- It is just a mine oppinion but I think to the description of strpos should be added the return value BOOLEAN not only INT because the return value is either INT if the string is found or BOOLEAN if the string is not find. Now it looks like: strpos ( string $haystack , mixed $needle [, int $offset = 0 ] ) : int I think it should be something like: strpos ( string $haystack , mixed $needle [, int $offset = 0 ] ) : {int|boolena} Expected result: ---------------- strpos ( string $haystack , mixed $needle [, int $offset = 0 ] ) : {int|boolena} Actual result: -------------- strpos ( string $haystack , mixed $needle [, int $offset = 0 ] ) : int ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=78417&edit=1

« previous php.doc.bugs (#18588) next »