From c7581dedee916a3a498b36bb28c879230e530840 Mon Sep 17 00:00:00 2001 From: Egon Schmid Date: Wed, 15 Dec 1999 18:10:52 +0000 Subject: [PATCH] Some cosmetic changes. git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@17255 c90b9560-bf6c-de11-be94-00142212c4b1 --- functions/imap.xml | 874 ++++++++++++++++++++++++++++++--------------- 1 file changed, 580 insertions(+), 294 deletions(-) diff --git a/functions/imap.xml b/functions/imap.xml index 9b20788ee5..dc8aca9046 100644 --- a/functions/imap.xml +++ b/functions/imap.xml @@ -5,24 +5,29 @@ To get these functions to work, you have to compile PHP with - . That requires the c-client library to be - installed. Grab the latest version from ftp://ftp.cac.washington.edu/imap/ + . That requires the + c-client library to be installed. Grab the latest version from + ftp://ftp.cac.washington.edu/imap/ and compile it. Then copy c-client/c-client.a to /usr/local/lib or some other directory on your link path and copy c-client/rfc822.h, mail.h and linkage.h to /usr/local/include or some other directory - in your include path. + in your include path. + - Note that these functions are not limited to the IMAP protocol, despite - their name. The underlying c-client library also supports NNTP, POP3 and - local mailbox access methods. See the imap_open for - more information. + Note that these functions are not limited to the IMAP protocol, + despite their name. The underlying c-client library also supports + NNTP, POP3 and local mailbox access methods. See the + imap_open for more information. - imap_append - Append a string message to a specified mailbox + imap_append + + Append a string message to a specified mailbox + Description @@ -34,12 +39,14 @@ stringflags - Returns true on sucess, false on error. + Returns true on sucess, false on error. + imap_append appends a string message to the specified mailbox mbox. If the optional flags is specified, writes the - flags to that mailbox also. + flags to that mailbox also. + When talking to the Cyrus IMAP server, you must use "\r\n" as your end-of-line terminator instead of "\n" or the operation will @@ -60,7 +67,8 @@ imap_base64 function decodes BASE-64 encoded - text. The decoded message is returned as a string. + text. The decoded message is returned as a string. + @@ -84,18 +92,27 @@ mailbox. The optional flags are a bit mask with one or more of the following: - - FT_UID - The msgno is a UID - - FT_PEEK - Do not set the \Seen flag if not already set - + + + FT_UID - The msgno is a UID + + + + + FT_PEEK - Do not set the \Seen flag if not already set + + + + FT_INTERNAL - The return string is in internal format, will - not canonicalize to CRLF. - + not canonicalize to CRLF. + + + + - imap_check @@ -109,11 +126,13 @@ Returns information about the current mailbox. Returns FALSE on - failure. + failure. + The imap_check function checks the current mailbox status on the server and returns the information in an - object with following properties. + object with following properties. + @@ -123,12 +142,11 @@ Nmsgs : number of messages Recent : number of recent messages - + + - - imap_close @@ -144,7 +162,8 @@ Close the imap stream. Takes an optional flag CL_EXPUNGE, which will silently - expunge the mailbox before closing. + expunge the mailbox before closing. + @@ -164,19 +183,24 @@ imap_createmailbox creates a new mailbox specified by mbox (see imap_open for the format - of mbox names). + of mbox names). + - Returns true on success and false on error. + Returns true on success and false on error. + - See also imap_renamemailbox and imap_deletemailbox. + See also imap_renamemailbox and + imap_deletemailbox. + - imap_delete - Mark a messge for deletion from current mailbox + + Mark a messge for deletion from current mailbox + Description @@ -186,16 +210,17 @@ int msg_number - Returns true. - + Returns true. + + imap_delete function marks message pointed by msg_number for deletion. Actual deletion of the messages is done by - imap_expunge. + imap_expunge. + - imap_deletemailbox @@ -211,15 +236,18 @@ imap_deletemailbox deletes the specified mailbox (see imap_open for the format - of mbox names). + of mbox names). + - Returns true on success and false on error. + Returns true on success and false on error. + - See also imap_createmailbox and imap_reanmemailbox. + See also imap_createmailbox and + imap_reanmemailbox. + - imap_expunge @@ -235,11 +263,11 @@ imap_expunge deletes all the messages marked for deletion by imap_delete. - Returns true. + Returns true. + - imap_fetchbody @@ -260,32 +288,46 @@ of the specified messages as a text string and returns that text string. The section specification is a string of integers delimited by period which index into a body part list as per the - IMAP4 specification. Body parts are not decoded by this function. + IMAP4 specification. Body parts are not decoded by this function. + The options for imap_fetchbody e a bitmask with one or more of the following - - FT_UID - The msgono is a UID - - FT_PEEK - Do not set the \Seen flag if not already set - - FT_INTERNAL - The return string is in "internal" format, without - any attempt to canonicalize CRLF - + + + FT_UID - The msgono is a UID + + + + + FT_PEEK - Do not set the \Seen flag if not already set + + + + + FT_INTERNAL - The return string is in "internal" format, + without any attempt to canonicalize CRLF + + + + - - imap_fetchstructure - Read the structure of a particular message + imap_fetchstructure + + Read the structure of a particular message + Description - object imap_fetchstructure + object + imap_fetchstructure + int imap_stream int msg_number int @@ -421,7 +463,6 @@ - Transfer encodings @@ -437,11 +478,9 @@
-
- imap_header @@ -464,21 +503,32 @@ - This function returns an object of various header elements + This function returns an object of various header elements. + - remail,date,Date,subject,Subject,in_reply_to,message_id,newsgroups, - followup_to,references + remail, date, Date, subject, Subject, in_reply_to, message_id, + newsgroups, followup_to, references message flags: - Recent - 'R' if recent and seen, 'N' if recent and not seen, ' ' if not recent - Unseen - 'U' if not seen AND not recent, ' ' if seen OR not seen and recent - Answered - 'A' if answered, ' ' if unanswered - Deleted - 'D' if deleted, ' ' if not deleted - Draft - 'X' if draft, ' ' if not draft - Flagged - 'F' if flagged, ' ' if not flagged -NOTE that the Recent/Unseen behavior is a little odd. If you want to know if a message is Unseen, you must check for + Recent - 'R' if recent and seen, + 'N' if recent and not seen, + ' ' if not recent + Unseen - 'U' if not seen AND not recent, + ' ' if seen OR not seen and recent + Answered -'A' if answered, + ' ' if unanswered + Deleted - 'D' if deleted, + ' ' if not deleted + Draft - 'X' if draft, + ' ' if not draft + Flagged - 'F' if flagged, + ' ' if not flagged + +NOTE that the Recent/Unseen behavior is a little odd. If you want to +know if a message is Unseen, you must check for + Unseen == 'U' || Recent == 'N' toaddress (full to: line, up to 1024 characters) @@ -512,7 +562,8 @@ bcc[] (returns an array of objects from the Bcc line, containing:) host reply_toaddress (full reply_to: line, up to 1024 characters) -reply_to[] (returns an array of objects from the Reply_to line, containing:) +reply_to[] (returns an array of objects from the Reply_to line, +containing:) personal adl mailbox @@ -526,25 +577,31 @@ sender[] (returns an array of objects from the sender line, containing:) host return_path (full return-path: line, up to 1024 characters) -return_path[] (returns an array of objects from the return_path line, containing:) +return_path[] (returns an array of objects from the return_path line, +containing:) personal adl mailbox host -udate ( mail message date in unix time) +udate (mail message date in unix time) + +fetchfrom (from line formatted to fit fromlength +characters) -fetchfrom (from line formatted to fit fromlength characters) fetchsubject (subject line formatted to fit subjectlength characters) - + + imap_headers - Returns headers for all messages in a mailbox + + Returns headers for all messages in a mailbox + Description @@ -554,11 +611,11 @@ fetchsubject (subject line formatted to fit subjectlength Returns an array of string formatted with header info. One - element per mail message. + element per mail message. + - imap_listmailbox @@ -573,15 +630,18 @@ fetchsubject (subject line formatted to fit subjectlength string pat - Returns an array containing the names of the mailboxes. + Returns an array containing the names of the mailboxes. + - imap_getmailboxes - Read the list of mailboxes, returning detailed information on each one + + Read the list of mailboxes, returning detailed information on + each one + Description @@ -599,22 +659,39 @@ fetchsubject (subject line formatted to fit subjectlength this mailbox is in; and attributes. Attributes is a bitmask that can be tested against: - - - LATT_NOINFERIORS - This mailbox has no "children" (there are no mailboxes below this one) - - LATT_NOSELECT - This is only a container, not a mailbox - you cannot open it. - - LATT_MARKED - This mailbox is marked. Only used by UW-IMAPD. - - LATT_UNMARKED - This mailbox is not marked. Only used by UW-IMAPD. - + + + + LATT_NOINFERIORS - This mailbox has no "children" (there are + no mailboxes below this one) + + + + + LATT_NOSELECT - This is only a container, not a mailbox - you + cannot open it. + + + + + LATT_MARKED - This mailbox is marked. Only used by UW-IMAPD. + + + + + LATT_UNMARKED - This mailbox is not marked. Only used by + UW-IMAPD. + + + + ref should normally be just the IMAP server, in the form: {imap_server:imap_port}, and pattern specifies where in the mailbox hierarchy to start searching. If you want all mailboxes, pass - pattern as an empty string. + pattern as an empty string. + There are two special characters you can pass as part of the pattern: '*' and '%'. '*' means to return @@ -624,11 +701,11 @@ fetchsubject (subject line formatted to fit subjectlength pattern parameter will return only the top level mailboxes; '~/mail/%' on UW_IMAPD will return every mailbox in the ~/mail directory, but none in subfolders of that - directory. + directory. + - imap_listsubscribed @@ -647,11 +724,11 @@ fetchsubject (subject line formatted to fit subjectlength subscribed. The ref and pattern arguments specify the base location to search from and the pattern the mailbox name must - match. + match. + - imap_getsubscribed @@ -668,11 +745,11 @@ fetchsubject (subject line formatted to fit subjectlength This function is identical to imap_getmailboxes, except that it only - returns mailboxes that the user is subscribed to. + returns mailboxes that the user is subscribed to. + - imap_mail_copy @@ -688,24 +765,32 @@ fetchsubject (subject line formatted to fit subjectlength int flags - Returns true on success and false on error. + Returns true on success and false on error. + Copies mail messages specified by msglist to specified mailbox. msglist is a range - not just message numbers. + not just message numbers. + - flags is a bitmask of one or more of + Flags is a bitmask of one or more of - - CP_UID - the sequence numbers contain UIDS - + + + CP_UID - the sequence numbers contain UIDS + + + + CP_MOVE - Delete the messages from the current mailbox after - copying - + copying + + + + - imap_mail_move @@ -722,18 +807,20 @@ fetchsubject (subject line formatted to fit subjectlength Moves mail messages specified by msglist to specified mailbox. msglist is a range - not just message numbers. + not just message numbers. + - Returns true on success and false on error. + Returns true on success and false on error. + - imap_num_msg - Gives the number of messages in the current - mailbox + + Gives the number of messages in the current mailbox + Description @@ -742,11 +829,11 @@ fetchsubject (subject line formatted to fit subjectlength int imap_stream - Return the number of messages in the current mailbox. + Return the number of messages in the current mailbox. + - imap_num_recent @@ -760,12 +847,11 @@ fetchsubject (subject line formatted to fit subjectlength int imap_stream - Returns the number of recent messages in the current mailbox. - + Returns the number of recent messages in the current mailbox. + - imap_open @@ -784,7 +870,7 @@ fetchsubject (subject line formatted to fit subjectlength Returns an IMAP stream on success and false on error. This function can also be used to open streams to POP3 and NNTP servers. To connect to an IMAP server running on port 143 on the - local machine, do the following: + local machine, do the following: $mbox = imap_open("{localhost:143}INBOX","user_id","password"); @@ -794,7 +880,7 @@ $mbox = imap_open("{localhost:143}INBOX","user_id","password"); To connect to a POP3 server on port 110 on the local server, use: - + $mbox = imap_open("{localhost/pop3:110}INBOX","user_id","password"); @@ -802,30 +888,43 @@ $mbox = imap_open("{localhost/pop3:110}INBOX","user_id","password"); To connect to an NNTP server on port 119 on the local server, use: - + $nntp = imap_open("{localhost/nntp:119}comp.test","",""); To connect to a remote server replace "localhost" with the name - or the IP address of the server you want to connect to. + or the IP address of the server you want to connect to. + The options are a bit mask with one or more of the following: - - OP_READONLY - Open mailbox read-only - - OP_ANONYMOUS - Dont use or update a .newsrc for news - + + + OP_READONLY - Open mailbox read-only + + + + + OP_ANONYMOUS - Dont use or update a .newsrc for news + + + + OP_HALFOPEN - For IMAP and NNTP names, open a connection but - dont open a mailbox - - CL_EXPUNGE - Expunge mailbox automatically upon mailbox close - + dont open a mailbox + + + + + CL_EXPUNGE - Expunge mailbox automatically upon mailbox close + + + + - imap_ping @@ -838,16 +937,17 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); int imap_stream - Returns true if the stream is still alive, false otherwise. + Returns true if the stream is still alive, false otherwise. + imap_ping function pings the stream to see it is still active. It may discover new mail; this is the preferred method for a periodic "new mail check" as well as a - "keep alive" for servers which have inactivity timeout. + "keep alive" for servers which have inactivity timeout. + - imap_renamemailbox @@ -861,17 +961,21 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); string old_mbox string new_mbox - - This function renames on old mailbox to new mailbox (see imap_open for the format - of mbox names). + + This function renames on old mailbox to new mailbox (see + imap_open for the format of + mbox names). + - Returns true on success and false on error. + Returns true on success and false on error. + - See also imap_createmailbox and imap_deletemailbox. + See also imap_createmailbox and + imap_deletemailbox. + - imap_reopen @@ -893,20 +997,32 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); The options are a bit mask with one or more of the following: - - OP_READONLY - Open mailbox read-only - - OP_ANONYMOUS - Dont use or update a .newsrc for news - + + + OP_READONLY - Open mailbox read-only + + + + + OP_ANONYMOUS - Dont use or update a .newsrc for news + + + + OP_HALFOPEN - For IMAP and NNTP names, open a connection but - dont open a mailbox - - CL_EXPUNGE - Expunge mailbox automatically upon mailbox close - + dont open a mailbox + + + + + CL_EXPUNGE - Expunge mailbox automatically upon mailbox close + + + + - imap_subscribe @@ -920,17 +1036,20 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); string mbox - Subscribe to a new mailbox. + Subscribe to a new mailbox. + - Returns true on success and false on error. + Returns true on success and false on error. + - - imap_undelete - Unmark the message which is marked deleted + imap_undelete + + Unmark the message which is marked deleted + Description @@ -941,13 +1060,14 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); This function removes the deletion flag for a specified message, - which is set by imap_delete. + which is set by imap_delete. + - Returns true on success and false on error. + Returns true on success and false on error. + - imap_unsubscribe @@ -961,9 +1081,11 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); string mbox - Unsubscribe from a specified mailbox. + Unsubscribe from a specified mailbox. + - Returns true on success and false on error. + Returns true on success and false on error. + @@ -989,7 +1111,9 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); imap_8bit - Convert an 8bit string to a quoted-printable string. + + Convert an 8bit string to a quoted-printable string + Description @@ -1007,7 +1131,9 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); imap_binary - Convert an 8bit string to a base64 string. + + Convert an 8bit string to a base64 string + Description @@ -1016,17 +1142,21 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); string string - Convert an 8bit string to a base64 string. + Convert an 8bit string to a base64 string. + - Returns a base64 string + Returns a base64 string. + imap_scanmailbox - Read the list of mailboxes, takes a string to search - for in the text of the mailbox + + Read the list of mailboxes, takes a string to search for in the + text of the mailbox + Description @@ -1037,7 +1167,8 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); Returns an array containing the names of the mailboxes that have - string in the text of the mailbox. + string in the text of the mailbox. + @@ -1053,11 +1184,14 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); int imap_stream - Returns information about the current mailbox. Returns FALSE on failure. - + Returns information about the current mailbox. Returns FALSE on + failure. + + The imap_mailboxmsginfo function checks the current mailbox status on the server and returns the information - in an object with following properties. + in an object with following properties. + @@ -1069,28 +1203,33 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); Unread : number of unread messages Size : mailbox size - + + - imap_rfc822_write_address - Returns a properly formatted email address given the - mailbox, host, and personal info. + + Returns a properly formatted email address given the mailbox, + host, and personal info. + Description - string imap_rfc822_write_address + string + imap_rfc822_write_address + string mailbox string host string personal Returns a properly formatted email address given the mailbox, - host, and personal info. + host, and personal info. + @@ -1102,13 +1241,16 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); Description - string imap_rfc822_parse_adrlist + string + imap_rfc822_parse_adrlist + string address string default_host This function parses the address string and for each address, - returns an array of objects. The 4 objects are: + returns an array of objects. The 4 objects are: + @@ -1117,7 +1259,8 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); personal - the personal name adl - at domain source route - + + @@ -1137,16 +1280,22 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); This function causes a store to add the specified flag to the - flags set for the messages in the specified sequence. - The flags which you can set are "\\Seen", "\\Answered", "\\Flagged", "\\Deleted", "\\Draft", and "\\Recent" ( as defined by RFC2060) + flags set for the messages in the specified sequence. + + + The flags which you can set are "\\Seen", "\\Answered", + "\\Flagged", "\\Deleted", "\\Draft", and "\\Recent" ( as defined + by RFC2060) + The options are a bit mask with one or more of the following: ST_UID The sequence argument contains UIDs instead of - sequence numbers + sequence numbers - + + @@ -1158,7 +1307,9 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); Description - string imap_clearflag_full + string + imap_clearflag_full + int stream string sequence string flag @@ -1166,15 +1317,17 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); This function causes a store to delete the specified flag to the - flags set for the messages in the specified sequence. + flags set for the messages in the specified sequence. + The options are a bit mask with one or more of the following: ST_UID The sequence argument contains UIDs instead of - sequence numbers + sequence numbers - + + @@ -1194,22 +1347,25 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); Returns an array of message numbers sorted by the given - parameters + parameters + - Rev is 1 for reverse-sorting. + Rev is 1 for reverse-sorting. + Criteria can be one (and only one) of the following: - SORTDATE message Date - SORTARRIVAL arrival date - SORTFROM mailbox in first From address - SORTSUBJECT message Subject - SORTTO mailbox in first To address - SORTCC mailbox in first cc address - SORTSIZE size of message in octets + SORTDATE message Date + SORTARRIVAL arrival date + SORTFROM mailbox in first From address + SORTSUBJECT message Subject + SORTTO mailbox in first To address + SORTCC mailbox in first cc address + SORTSIZE size of message in octets - + + The flags are a bitmask of one or more of the following: @@ -1217,11 +1373,11 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); SE_UID Return UIDs instead of sequence numbers SE_NOPREFETCH Don't prefetch searched messages. - + + - imap_fetchheader @@ -1238,30 +1394,34 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); This function causes a fetch of the complete, unfiltered RFC 822 format header of the specified message as a text string and - returns that text string. + returns that text string. + The options are: FT_UID The msgno argument is a UID FT_INTERNAL The return string is in "internal" format, - without any attempt to canonicalize to CRLF - newlines + without any attempt to canonicalize to CRLF + newlines FT_PREFETCHTEXT The RFC822.TEXT should be pre-fetched at the - same time. This avoids an extra RTT on an - IMAP connection if a full message text is - desired (e.g. in a "save to local file" - operation) + same time. This avoids an extra RTT on an + IMAP connection if a full message text is + desired (e.g. in a "save to local file" + operation) - + + imap_uid - This function returns the UID for the given message - sequence number. + + This function returns the UID for the given message sequence + number + Description @@ -1272,7 +1432,8 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); This function returns the UID for the given message sequence - number. It is the inverse of imap_msgno. + number. It is the inverse of imap_msgno. + @@ -1280,7 +1441,10 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); imap_msgno - This function returns the message sequence number for the given UID. + + This function returns the message sequence number for the given + UID. + Description @@ -1291,15 +1455,18 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); This function returns the message sequence number for the given - UID. It is the inverse of imap_uid. + UID. It is the inverse of imap_uid. + - imap_search - This function returns an array of messages matching the given search criteria. + + This function returns an array of messages matching the given + search criteria. + Description @@ -1313,75 +1480,154 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); This function performs a search on the mailbox currently opened in the given imap stream. criteria is a string, delimited by spaces, in which the following keywords are - allowed. Any multi-word arguments (eg FROM "joe smith") must be + allowed. Any multi-word arguments (eg FROM "joey smith") must be quoted. - - - ALL - return all messages matching the rest of the criteria - - ANSWERED - match messages with the \\ANSWERED flag set - - BCC "string" - match messages with "string" in the Bcc: field - - BEFORE "date" - match messages with Date: before "date" - - BODY "string" - match messages with "string" in the body of the message - - CC "string" - match messages with "string" in the Cc: field - - DELETED - match deleted messages - - FLAGGED - match messages with the \\FLAGGED (sometimes referred to as Important or Urgent) flag set - - FROM "string" - match messages with "string" in the From: field - - KEYWORD "string" - match messages with "string" as a keyword - - NEW - match new messages - - OLD - match old messages - - ON "date" - match messages with Date: matching "date" - - RECENT - match messages with the \\RECENT flag set - - SEEN - match messages that have been read (the \\SEEN flag is set) - - SINCE "date" - match messages with Date: after "date" - - SUBJECT "string" - match messages with "string" in the Subject: - - TEXT "string" - match messages with text "string" - - TO "string" - match messages with "string" in the To: - - UNANSWERED - match messages that have not been answered - - UNDELETED - match messages that are not deleted - - UNFLAGGED - match messages that are not flagged - - UNKEYWORD "string" - match messages that do not have the keyword "string" - - UNSEEN - match messages which have not been read yet - + + + + ALL - return all messages matching the rest of the criteria + + + + + ANSWERED - match messages with the \\ANSWERED flag set + + + + + BCC "string" - match messages with "string" in the Bcc: field + + + + + BEFORE "date" - match messages with Date: before "date" + + + + + BODY "string" - match messages with "string" in the body of the message + + + + + CC "string" - match messages with "string" in the Cc: field + + + + + DELETED - match deleted messages + + + + + FLAGGED - match messages with the \\FLAGGED (sometimes + referred to as Important or Urgent) flag set + + + + + FROM "string" - match messages with "string" in the From: field + + + + + KEYWORD "string" - match messages with "string" as a keyword + + + + + NEW - match new messages + + + + + OLD - match old messages + + + + + ON "date" - match messages with Date: matching "date" + + + + + RECENT - match messages with the \\RECENT flag set + + + + + SEEN - match messages that have been read (the \\SEEN flag is set) + + + + + SINCE "date" - match messages with Date: after "date" + + + + + SUBJECT "string" - match messages with "string" in the Subject: + + + + + TEXT "string" - match messages with text "string" + + + + + TO "string" - match messages with "string" in the To: + + + + + UNANSWERED - match messages that have not been answered + + + + + UNDELETED - match messages that are not deleted + + + + + UNFLAGGED - match messages that are not flagged + + + + + UNKEYWORD "string" - match messages that do not have the + keyword "string" + + + + + UNSEEN - match messages which have not been read yet + + + + For example, to match all unanswered messages sent by Mom, you'd use: "UNANSWERED FROM mom". Searches appear to be case insensitive. This list of criteria is from a reading of the UW c-client source code and may be uncomplete or - inaccurate. Searcher beware. + inaccurate. Searcher beware. + Valid values for flags are SE_UID, which causes the returned - array to contain UIDs instead of messages sequence numbers. + array to contain UIDs instead of messages sequence numbers. + - imap_last_error - This function returns the last IMAP error (if any) that occurred during this page request. + + This function returns the last IMAP error (if any) that occurred + during this page request. + Description @@ -1394,16 +1640,21 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); message that occurred on the current page. The error stack is untouched; calling imap_last_error subsequently, with no intervening errors, will return the same - error. - CAUTION: this function is not yet available in PHP4 + error. + + CAUTION: this function is not yet available in PHP4. + - imap_errors - This function returns all of the IMAP errors (if any) that have occurred during this page request or since the error stack was reset. + + This function returns all of the IMAP errors (if any) that have + occurred during this page request or since the error stack was + reset. + Description @@ -1416,16 +1667,22 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); generated since the last imap_errors call, or the beginning of the page. When imap_errors is called, the error stack is - subsequently cleared. - CAUTION: this function is not yet available in PHP4 + subsequently cleared. + + + CAUTION: this function is not yet available in PHP4 + - imap_alerts - This function returns all IMAP alert messages (if any) that have occurred during this page request or since the alert stack was reset. + + This function returns all IMAP alert messages (if any) that have + occurred during this page request or since the alert stack was + reset. + Description @@ -1439,15 +1696,18 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); or the beginning of the page. When imap_alerts is called, the alert stack is subsequently cleared. The IMAP specification requires that these - messages be passed to the user. + messages be passed to the user. + - imap_status - This function returns status information on a mailbox other than the current one. + + This function returns status information on a mailbox other than + the current one. + Description @@ -1458,24 +1718,50 @@ $nntp = imap_open("{localhost/nntp:119}comp.test","",""); int options - This function returns an object containing status information. Valid flags are: - - - SA_MESSAGES - set status->messages to the number of messages in the mailbox - - SA_RECENT - set status->recent to the number of recent messages in the mailbox - - SA_UNSEEN - set status->unseen to the number of unseen (new) messages in the mailbox - - SA_UIDNEXT - set status->uidnext to the next uid to be used in the mailbox - - SA_UIDVALIDITY - set status->uidvalidity to a constant that changes when uids for the mailbox may no longer be valid - - SA_ALL - set all of the above - + This function returns an object containing status + information. Valid flags are: + + + + SA_MESSAGES - set status->messages to the number of messages + in the mailbox + + + + + SA_RECENT - set status->recent to the number of recent + messages in the mailbox + + + + + SA_UNSEEN - set status->unseen to the number of unseen (new) + messages in the mailbox + + + + + SA_UIDNEXT - set status->uidnext to the next uid to be used in + the mailbox + + + + + SA_UIDVALIDITY - set status->uidvalidity to a constant that + changes when uids for the mailbox may no longer be valid + + + + + SA_ALL - set all of the above + + + + status->flags is also set, which contains a bitmask which can be - checked against any of the above constants. + checked against any of the above constants. + @@ -1491,7 +1777,7 @@ sgml-always-quote-attributes:t sgml-indent-step:1 sgml-indent-data:t sgml-parent-document:nil -sgml-default-dtd-file:"../manual.ced" +sgml-default-dtd-file:"../../manual.ced" sgml-exposed-tags:nil sgml-local-catalogs:nil sgml-local-ecat-files:nil