Doc #64199 [Com]: PHP Notice: Unknown: Sequence out of range (errflg=2) in Unknown on line 0

From: Date: Wed, 19 Oct 2016 11:46:46 +0000
Subject: Doc #64199 [Com]: PHP Notice: Unknown: Sequence out of range (errflg=2) in Unknown on line 0
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-14032@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=64199&edit=1 ID: 64199 Comment by: pariharvikram1989 at gmail dot com Reported by: yvan+php at redcell dot ca Summary: PHP Notice: Unknown: Sequence out of range (errflg=2) in Unknown on line 0 Status: Assigned Type: Documentation Problem Package: IMAP related PHP Version: 5.4.11 Assigned To: kriscraig Block user comment: N Private report: N New Comment: imap_search($inbox,'SUBJECT "Employee Wise Monthly Report"', SE_UID); i was using this syntax and i got error PHP Notice: Unknown: Sequence out of range (errflg=2) in Unknown on line 0. Then I removed SE_UID and rewrite imap_search($inbox,'SUBJECT "Employee Wise Monthly Report"', SE_UID); My code.. then its worked fine Previous Comments: ------------------------------------------------------------------------ [2013-09-22 04:08:47] rob at svosolutions dot com A workaround is to check the number of messages before calling imap_fetch_overview: $check = imap_check($mbox); if ($check->Nmsgs == 0) { imap_close($mbox); } ------------------------------------------------------------------------ [2013-08-28 15:34:43] pheagey at gmail dot com Would be nice to have a more clearly defined error message when imap_num_msg() returns is empty. Like, null or 0 would be nice. ------------------------------------------------------------------------ [2013-02-12 17:20:31] yvan+php at redcell dot ca Description: ------------ --- From manual page: http://www.php.net/function.imap-fetch-overview --- Please add a note to this page that using a sequence outside the range of existing messages, or more importantly, a range of 1:1 when there aren't any messages, will result in the notice: PHP Notice: Unknown: Sequence out of range (errflg=2) in Unknown on line 0 ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=64199&edit=1

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