note 114392 added to function.imap-search
| From: | mail at nikha dot org | Date: | Fri, 14 Feb 2014 22:18:15 +0000 |
| Subject: | note 114392 added to function.imap-search | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-198516@lists.php.net to get a copy of this message | ||
Hi,
be aware, that imap_search() does NOT (as you may exspect) return an empty array, if nothing was
found!
As the manual says, it returns FALSE.
Do not test the result like "count($array)" as I did.
This gives you 1 for an empty result. Took me an hour to found out why :-( RTFM
----
Server IP: 213.172.110.14
Probable Submitter: 88.130.132.189
----
Manual Page -- http://php.net/manual/en/function.imap-search.php
Edit -- https://master.php.net/note/edit/114392
Del: integrated -- https://master.php.net/note/delete/114392/integrated
Del: useless -- https://master.php.net/note/delete/114392/useless
Del: bad code -- https://master.php.net/note/delete/114392/bad+code
Del: spam -- https://master.php.net/note/delete/114392/spam
Del: non-english -- https://master.php.net/note/delete/114392/non-english
Del: in docs -- https://master.php.net/note/delete/114392/in+docs
Del: other reasons-- https://master.php.net/note/delete/114392
Reject -- https://master.php.net/note/reject/114392
Search -- https://master.php.net/manage/user-notes.php