From 9cf41289247b5a0e268545da2c319a2d0b8f06f5 Mon Sep 17 00:00:00 2001 From: Mehdi Achour Date: Sun, 14 Jan 2007 15:37:21 +0000 Subject: [PATCH] WS, prepare for new doc style git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@227216 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/imap/functions/imap-8bit.xml | 53 +-- reference/imap/functions/imap-alerts.xml | 55 +-- reference/imap/functions/imap-append.xml | 79 ++- reference/imap/functions/imap-base64.xml | 49 +- reference/imap/functions/imap-binary.xml | 51 +- reference/imap/functions/imap-body.xml | 101 ++-- reference/imap/functions/imap-bodystruct.xml | 41 +- reference/imap/functions/imap-check.xml | 131 +++-- .../imap/functions/imap-clearflag-full.xml | 81 ++-- reference/imap/functions/imap-close.xml | 49 +- .../imap/functions/imap-createmailbox.xml | 77 ++- reference/imap/functions/imap-delete.xml | 105 ++-- .../imap/functions/imap-deletemailbox.xml | 59 ++- reference/imap/functions/imap-errors.xml | 55 +-- reference/imap/functions/imap-expunge.xml | 47 +- .../imap/functions/imap-fetch-overview.xml | 235 +++++---- reference/imap/functions/imap-fetchbody.xml | 105 ++-- reference/imap/functions/imap-fetchheader.xml | 97 ++-- .../imap/functions/imap-fetchstructure.xml | 293 ++++++------ reference/imap/functions/imap-get-quota.xml | 163 ++++--- .../imap/functions/imap-get-quotaroot.xml | 114 +++-- reference/imap/functions/imap-getacl.xml | 48 +- .../imap/functions/imap-getmailboxes.xml | 176 ++++--- .../imap/functions/imap-getsubscribed.xml | 43 +- reference/imap/functions/imap-header.xml | 3 +- reference/imap/functions/imap-headerinfo.xml | 143 +++--- reference/imap/functions/imap-headers.xml | 39 +- reference/imap/functions/imap-last-error.xml | 52 +- reference/imap/functions/imap-list.xml | 64 +-- reference/imap/functions/imap-listmailbox.xml | 3 +- reference/imap/functions/imap-listscan.xml | 63 ++- .../imap/functions/imap-listsubscribed.xml | 3 +- reference/imap/functions/imap-lsub.xml | 40 +- .../imap/functions/imap-mail-compose.xml | 51 +- reference/imap/functions/imap-mail-copy.xml | 89 ++-- reference/imap/functions/imap-mail-move.xml | 77 ++- reference/imap/functions/imap-mail.xml | 77 ++- .../imap/functions/imap-mailboxmsginfo.xml | 155 +++--- .../functions/imap-mime-header-decode.xml | 79 ++- reference/imap/functions/imap-msgno.xml | 50 +- reference/imap/functions/imap-num-msg.xml | 45 +- reference/imap/functions/imap-num-recent.xml | 45 +- reference/imap/functions/imap-open.xml | 449 +++++++++--------- reference/imap/functions/imap-ping.xml | 61 ++- reference/imap/functions/imap-qprint.xml | 47 +- .../imap/functions/imap-renamemailbox.xml | 61 ++- reference/imap/functions/imap-reopen.xml | 115 +++-- .../functions/imap-rfc822-parse-adrlist.xml | 109 +++-- .../functions/imap-rfc822-parse-headers.xml | 41 +- .../functions/imap-rfc822-write-address.xml | 64 ++- reference/imap/functions/imap-scanmailbox.xml | 3 +- reference/imap/functions/imap-search.xml | 328 +++++++------ reference/imap/functions/imap-set-quota.xml | 99 ++-- reference/imap/functions/imap-setacl.xml | 57 ++- .../imap/functions/imap-setflag-full.xml | 105 ++-- reference/imap/functions/imap-sort.xml | 169 ++++--- reference/imap/functions/imap-status.xml | 144 +++--- reference/imap/functions/imap-subscribe.xml | 49 +- reference/imap/functions/imap-thread.xml | 87 ++-- reference/imap/functions/imap-timeout.xml | 34 +- reference/imap/functions/imap-uid.xml | 64 ++- reference/imap/functions/imap-undelete.xml | 61 ++- reference/imap/functions/imap-unsubscribe.xml | 49 +- reference/imap/functions/imap-utf7-decode.xml | 77 ++- reference/imap/functions/imap-utf7-encode.xml | 67 ++- reference/imap/functions/imap-utf8.xml | 49 +- 66 files changed, 2819 insertions(+), 2955 deletions(-) diff --git a/reference/imap/functions/imap-8bit.xml b/reference/imap/functions/imap-8bit.xml index fd2d26b97d..2fceeaa9ae 100644 --- a/reference/imap/functions/imap-8bit.xml +++ b/reference/imap/functions/imap-8bit.xml @@ -1,32 +1,29 @@ - - - - - imap_8bit - - Convert an 8bit string to a quoted-printable string - - - - Description - - stringimap_8bit - stringstring - - - Convert an 8bit string to a quoted-printable string (according to - RFC2045, section - 6.7). - - - Returns a quoted-printable string. - - - See also imap_qprint. - - - + + + + imap_8bit + Convert an 8bit string to a quoted-printable string + + + Description + + stringimap_8bit + stringstring + + + Convert an 8bit string to a quoted-printable string (according to + RFC2045, section + 6.7). + + + Returns a quoted-printable string. + + + See also imap_qprint. + + + - - - - 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 - - - - Description - - arrayimap_alerts - - - - This function returns an array of all of the IMAP alert messages - generated since the last imap_alerts call, - or the beginning of the page. Returns &false; if no alert messages are - available. When imap_alerts is called, the alert - stack is subsequently cleared. The IMAP specification requires that these - messages be passed to the user. - - - See also imap_errors - - - + + + + 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 + + + Description + + arrayimap_alerts + + + + This function returns an array of all of the IMAP alert messages + generated since the last imap_alerts call, + or the beginning of the page. Returns &false; if no alert messages are + available. When imap_alerts is called, the alert + stack is subsequently cleared. The IMAP specification requires that these + messages be passed to the user. + + + See also imap_errors + + + - - - - imap_append - - Append a string message to a specified mailbox - - - - Description - - boolimap_append - resourceimap_stream - stringmbox - stringmessage - stringoptions - - - imap_append appends a string message to the - specified mailbox mbox. If the optional - options is specified, writes the - options to that mailbox also. - - - &return.success; - - - 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 - fail. - - - - <function>imap_append</function> example - + + + + imap_append + Append a string message to a specified mailbox + + + Description + + boolimap_append + resourceimap_stream + stringmbox + stringmessage + stringoptions + + + imap_append appends a string message to the + specified mailbox mbox. If the optional + options is specified, writes the + options to that mailbox also. + + + &return.success; + + + 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 + fail. + + + + <function>imap_append</function> example + Nmsgs . "\n"; imap_close($stream); ?> ]]> - - - - - + + + + + - - - - imap_base64 - Decode BASE64 encoded text - - - Description - - stringimap_base64 - stringtext - - - imap_base64 function decodes BASE-64 encoded - text (see RFC2045, - Section 6.8). The decoded message is returned as a string. - - - See also imap_binary, - base64_encode and - base64_decode. - - - + + + + imap_base64 + Decode BASE64 encoded text + + + Description + + stringimap_base64 + stringtext + + + imap_base64 function decodes BASE-64 encoded + text (see RFC2045, + Section 6.8). The decoded message is returned as a string. + + + See also imap_binary, + base64_encode and + base64_decode. + + + - - - - imap_binary - - Convert an 8bit string to a base64 string - - - - Description - - stringimap_binary - stringstring - - - Convert an 8bit string to a base64 string (according to RFC2045, Section 6.8). - - - Returns a base64 string. - - - See also imap_base64. - - - + + + + imap_binary + Convert an 8bit string to a base64 string + + + Description + + stringimap_binary + stringstring + + + Convert an 8bit string to a base64 string (according to RFC2045, Section 6.8). + + + Returns a base64 string. + + + See also imap_base64. + + + - - - - imap_body - Read the message body - - - Description - - stringimap_body - resourceimap_stream - intmsg_number - intoptions - - - imap_body returns the body of the message, - numbered msg_number in the current - mailbox. - - - The optional options are a bit mask - with one or more of the following: - - - - FT_UID - The msg_number 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. - - - - - - imap_body will only return a verbatim copy of the - message body. To extract single parts of a multipart MIME-encoded - message you have to use imap_fetchstructure to - analyze its structure and imap_fetchbody to - extract a copy of a single body component. - - - + + + + imap_body + Read the message body + + + Description + + stringimap_body + resourceimap_stream + intmsg_number + intoptions + + + imap_body returns the body of the message, + numbered msg_number in the current + mailbox. + + + The optional options are a bit mask + with one or more of the following: + + + + FT_UID - The msg_number 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. + + + + + + imap_body will only return a verbatim copy of the + message body. To extract single parts of a multipart MIME-encoded + message you have to use imap_fetchstructure to + analyze its structure and imap_fetchbody to + extract a copy of a single body component. + + + - - - - imap_bodystruct - - Read the structure of a specified body section of a specific message - - - - Description - - objectimap_bodystruct - resourcestream_id - intmsg_no - stringsection - - - &warn.undocumented.func; - - - + + + + imap_bodystruct + Read the structure of a specified body section of a specific message + + + Description + + objectimap_bodystruct + resourcestream_id + intmsg_no + stringsection + + + &warn.undocumented.func; + + + - - - - imap_check - Check current mailbox - - - Description - - objectimap_check - resourceimap_stream - - - Returns information about the current mailbox. Returns &false; on - failure. - - - The imap_check function checks the current - mailbox status on the server and returns the information in an - object with following properties: - - - - - - Date - current system time formatted according to RFC2822 - - - - - Driver - protocol used to access this mailbox: POP3, IMAP, NNTP - - - - - Mailbox - the mailbox name - - - - - Nmsgs - number of messages in the mailbox - - - - - Recent - number of recent messages in the mailbox - - - - - - - <function>imap_check</function> example - + + + + imap_check + Check current mailbox + + + Description + + objectimap_check + resourceimap_stream + + + Returns information about the current mailbox. Returns &false; on + failure. + + + The imap_check function checks the current + mailbox status on the server and returns the information in an + object with following properties: + + + + + + Date - current system time formatted according to RFC2822 + + + + + Driver - protocol used to access this mailbox: POP3, IMAP, NNTP + + + + + Mailbox - the mailbox name + + + + + Nmsgs - number of messages in the mailbox + + + + + Recent - number of recent messages in the mailbox + + + + + + + <function>imap_check</function> example + ]]> - - - this will output : - - + + + this will output : + + @@ -83,11 +82,11 @@ object(stdClass)(5) { int(0) } ]]> - - - - - + + + + + - - - - imap_clearflag_full - Clears flags on messages - - - Description - - boolimap_clearflag_full - resourcestream - stringsequence - stringflag - stringoptions - - - This function causes a store to delete the specified - flag to the flags set for the - messages in the specified sequence. - The flags which you can unset are "\\Seen", "\\Answered", - "\\Flagged", "\\Deleted", and "\\Draft" (as defined - by RFC2060). &return.success;. - - - options are a bit mask and may contain - the single option: - - - - ST_UID - The sequence argument contains UIDs - instead of sequence numbers - - - - - - See also: imap_setflag_full. - - - + + + + imap_clearflag_full + Clears flags on messages + + + Description + + boolimap_clearflag_full + resourcestream + stringsequence + stringflag + stringoptions + + + This function causes a store to delete the specified + flag to the flags set for the + messages in the specified sequence. + The flags which you can unset are "\\Seen", "\\Answered", + "\\Flagged", "\\Deleted", and "\\Draft" (as defined + by RFC2060). &return.success;. + + + options are a bit mask and may contain + the single option: + + + + ST_UID - The sequence argument contains UIDs + instead of sequence numbers + + + + + + See also: imap_setflag_full. + + + - - - - imap_close - Close an IMAP stream - - - Description - - boolimap_close - resourceimap_stream - intflag - - - Closes the imap stream. Takes an optional - flag CL_EXPUNGE, - which will silently expunge the mailbox before closing, - removing all messages marked for deletion. - - - See also: imap_open. - - - + + + + imap_close + Close an IMAP stream + + + Description + + boolimap_close + resourceimap_stream + intflag + + + Closes the imap stream. Takes an optional + flag CL_EXPUNGE, + which will silently expunge the mailbox before closing, + removing all messages marked for deletion. + + + See also: imap_open. + + + - - - - imap_createmailbox - Create a new mailbox - - - Description - - boolimap_createmailbox - resourceimap_stream - stringmbox - - - imap_createmailbox creates a new mailbox - specified by mbox. Names containing - international characters should be encoded by imap_utf7_encode - - - &return.success;. - - - - <function>imap_createmailbox</function> example - + + + + imap_createmailbox + Create a new mailbox + + + Description + + boolimap_createmailbox + resourceimap_stream + stringmbox + + + imap_createmailbox creates a new mailbox + specified by mbox. Names containing + international characters should be encoded by imap_utf7_encode + + + &return.success;. + + + + <function>imap_createmailbox</function> example + \n"; // we will now create a new mailbox "phptestbox" in your inbox folder, // check its status after creation and finaly remove it to restore -// your inbox to its initial state +// your inbox to its initial state if (@imap_createmailbox($mbox, imap_utf7_encode("{imap.example.org}INBOX.$newname"))) { $status = @imap_status($mbox, "{imap.example.org}INBOX.$newname", SA_ALL); @@ -60,7 +59,7 @@ if (@imap_createmailbox($mbox, imap_utf7_encode("{imap.example.org}INBOX.$newnam } else { echo "imap_status on new mailbox failed: " . imap_last_error() . "
\n"; } - + if (@imap_deletemailbox($mbox, "{imap.example.org}INBOX.$newname")) { echo "new mailbox removed to restore initial state
\n"; } else { @@ -74,17 +73,17 @@ if (@imap_createmailbox($mbox, imap_utf7_encode("{imap.example.org}INBOX.$newnam imap_close($mbox); ?> ]]> -
-
-
- - See also imap_renamemailbox, - imap_deletemailbox and - imap_open for the format - of mbox names. - -
-
+
+
+
+ + See also imap_renamemailbox, + imap_deletemailbox and + imap_open for the format + of mbox names. + +
+
- - - - imap_delete - - Mark a message for deletion from current mailbox - - - - Description - - boolimap_delete - intimap_stream - intmsg_number - intoptions - - - Returns &true;. - - - imap_delete marks messages listed - in msg_number for deletion. The optional - flags parameter only has a single option, - FT_UID, which tells the function to treat - the msg_number argument as a - UID. Messages marked for deletion will - stay in the mailbox until either - imap_expunge is called or - imap_close is called with the optional - parameter CL_EXPUNGE. - - - - POP3 mailboxes do not have their message flags saved between - connections, so imap_expunge must be called during - the same connection in order for messages marked for deletion to - actually be purged. - - - - - <function>imap_delete</function> example - + + + + imap_delete + Mark a message for deletion from current mailbox + + + Description + + boolimap_delete + intimap_stream + intmsg_number + intoptions + + + Returns &true;. + + + imap_delete marks messages listed + in msg_number for deletion. The optional + flags parameter only has a single option, + FT_UID, which tells the function to treat + the msg_number argument as a + UID. Messages marked for deletion will + stay in the mailbox until either + imap_expunge is called or + imap_close is called with the optional + parameter CL_EXPUNGE. + + + + POP3 mailboxes do not have their message flags saved between + connections, so imap_expunge must be called during + the same connection in order for messages marked for deletion to + actually be purged. + + + + + <function>imap_delete</function> example + Nmsgs . "
\n"; imap_close($mbox); ?> ]]> -
-
-
- - See also: imap_undelete, - imap_expunge, and - imap_close. - -
-
+
+
+
+ + See also: imap_undelete, + imap_expunge, and + imap_close. + +
+
- - - - imap_deletemailbox - Delete a mailbox - - - Description - - boolimap_deletemailbox - resourceimap_stream - stringmbox - - - imap_deletemailbox deletes the specified - mailbox (see imap_open for the format - of mbox names). - - - &return.success;. - - - See also imap_createmailbox, - imap_renamemailbox, and - imap_open for the format of - mbox. - - - + + + + imap_deletemailbox + Delete a mailbox + + + Description + + boolimap_deletemailbox + resourceimap_stream + stringmbox + + + imap_deletemailbox deletes the specified + mailbox (see imap_open for the format + of mbox names). + + + &return.success;. + + + See also imap_createmailbox, + imap_renamemailbox, and + imap_open for the format of + mbox. + + + - - - - 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 - - - - Description - - arrayimap_errors - - - - This function returns an array of all of the IMAP error messages - generated since the last imap_errors call, - or the beginning of the page. Returns &false; if no error messages are - available. When imap_errors is called, the error - stack is subsequently cleared. - - - See also imap_last_error&listendand; - imap_alerts - - - + + + + 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 + + + Description + + arrayimap_errors + + + + This function returns an array of all of the IMAP error messages + generated since the last imap_errors call, + or the beginning of the page. Returns &false; if no error messages are + available. When imap_errors is called, the error + stack is subsequently cleared. + + + See also imap_last_error&listendand; + imap_alerts + + + - - - - imap_expunge - Delete all messages marked for deletion - - - Description - - boolimap_expunge - resourceimap_stream - - - imap_expunge deletes all the messages marked - for deletion by imap_delete, - imap_mail_move, or - imap_setflag_full. - - - Returns &true;. - - - + + + + imap_expunge + Delete all messages marked for deletion + + + Description + + boolimap_expunge + resourceimap_stream + + + imap_expunge deletes all the messages marked + for deletion by imap_delete, + imap_mail_move, or + imap_setflag_full. + + + Returns &true;. + + + - - - - imap_fetch_overview - - Read an overview of the information in the headers of the given message - - - - Description - - arrayimap_fetch_overview - resourceimap_stream - stringsequence - intoptions - - - This function fetches mail headers for the given - sequence and returns an overview of their - contents. sequence will contain a sequence - of message indices or UIDs, if flags - contains FT_UID. The returned value is an array of objects - describing one message header each: - - - - subject - the messages subject - - - - - from - who sent it - - - - - to - recipient - - - - - date - when was it sent - - - - - message_id - Message-ID - - - - - references - is a reference to this message id - - - - - in_reply_to - is a reply to this message id - - - - - size - size in bytes - - - - - uid - UID the message has in the mailbox - - - - - msgno - message sequence number in the mailbox - - - - - recent - this message is flagged as recent - - - - - flagged - this message is flagged - - - - - answered - this message is flagged as answered - - - - - deleted - this message is flagged for deletion - - - - - seen - this message is flagged as already read - - - - - draft - this message is flagged as being a draft - - - - - - - <function>imap_fetch_overview</function> example - + + + + imap_fetch_overview + Read an overview of the information in the headers of the given message + + + Description + + arrayimap_fetch_overview + resourceimap_stream + stringsequence + intoptions + + + This function fetches mail headers for the given + sequence and returns an overview of their + contents. sequence will contain a sequence + of message indices or UIDs, if flags + contains FT_UID. The returned value is an array of objects + describing one message header each: + + + + subject - the messages subject + + + + + from - who sent it + + + + + to - recipient + + + + + date - when was it sent + + + + + message_id - Message-ID + + + + + references - is a reference to this message id + + + + + in_reply_to - is a reply to this message id + + + + + size - size in bytes + + + + + uid - UID the message has in the mailbox + + + + + msgno - message sequence number in the mailbox + + + + + recent - this message is flagged as recent + + + + + flagged - this message is flagged + + + + + answered - this message is flagged as answered + + + + + deleted - this message is flagged for deletion + + + + + seen - this message is flagged as already read + + + + + draft - this message is flagged as being a draft + + + + + + + <function>imap_fetch_overview</function> example + msgno - $val->date - $val->subject\n"; } } - + imap_close($mbox); ?> ]]> - - - - - + + + + + - - - - imap_fetchbody - - Fetch a particular section of the body of the message - - - - Description - - stringimap_fetchbody - resourceimap_stream - intmsg_number - stringpart_number - intoptions - - - This function causes a fetch of a particular section of the body - 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. - - - The options for - imap_fetchbody is a bitmask with one or more - of the following: - - - - FT_UID - The msg_number 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. - - - - - - See also: imap_fetchstructure. - - - + + + + imap_fetchbody + Fetch a particular section of the body of the message + + + Description + + stringimap_fetchbody + resourceimap_stream + intmsg_number + stringpart_number + intoptions + + + This function causes a fetch of a particular section of the body + 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. + + + The options for + imap_fetchbody is a bitmask with one or more + of the following: + + + + FT_UID - The msg_number 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. + + + + + + See also: imap_fetchstructure. + + + - - - - imap_fetchheader - Returns header for a message - - - Description - - stringimap_fetchheader - resourceimap_stream - intmsgno - intoptions - - - This function causes a fetch of the complete, unfiltered - RFC2822 - format header of the specified message as a text string and - 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 - - - - - 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) - - - - - - + + + + imap_fetchheader + Returns header for a message + + + Description + + stringimap_fetchheader + resourceimap_stream + intmsgno + intoptions + + + This function causes a fetch of the complete, unfiltered + RFC2822 + format header of the specified message as a text string and + 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 + + + + + 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) + + + + + + - - - - imap_fetchstructure - - Read the structure of a particular message - - - - Description - - objectimap_fetchstructure - resourceimap_stream - intmsg_number - intoptions - - - This function fetches all the structured information for a given - message. The optional options parameter only - has a single option, FT_UID, which tells - the function to treat the msg_number - argument as a UID. The returned object - includes the envelope, internal date, size, flags and body - structure along with a similar object for each mime - attachment. The structure of the returned objects is as follows: - - - - - Returned Objects for <function>imap_fetchstructure</function> - - - - - type - Primary body type - - - encoding - Body transfer encoding - - - ifsubtype - &true; if there is a subtype string - - - subtype - MIME subtype - - - ifdescription - &true; if there is a description string - - - description - Content description string - - - ifid - &true; if there is an identification string - - - id - Identification string - - - lines - Number of lines - - - bytes - Number of bytes - - - ifdisposition - &true; if there is a disposition string - - - disposition - Disposition string - - - ifdparameters - &true; if the dparameters array exists - - - dparameters - An array of objects where each object has an "attribute" and a - "value" property corresponding to the parameters on the - Content-disposition MIMEheader. - - - ifparameters - &true; if the parameters array exists - - - parameters - An array of objects where each object has an "attribute" and - a "value" property. - - - parts - An array of objects identical in structure to the top-level - object, each of which corresponds to a MIME body - part. - - - -
-
- - - Primary body type - - - 0text - 1multipart - 2message - 3application - 4audio - 5image - 6video - 7other - - -
-
- - - Transfer encodings - - - 07BIT - 18BIT - 2BINARY - 3BASE64 - 4QUOTED-PRINTABLE - 5OTHER - - -
-
- - See also: imap_fetchbody. - -
-
+ + + + imap_fetchstructure + Read the structure of a particular message + + + Description + + objectimap_fetchstructure + resourceimap_stream + intmsg_number + intoptions + + + This function fetches all the structured information for a given + message. The optional options parameter only + has a single option, FT_UID, which tells + the function to treat the msg_number + argument as a UID. The returned object + includes the envelope, internal date, size, flags and body + structure along with a similar object for each mime + attachment. The structure of the returned objects is as follows: + + + + + Returned Objects for <function>imap_fetchstructure</function> + + + + + type + Primary body type + + + encoding + Body transfer encoding + + + ifsubtype + &true; if there is a subtype string + + + subtype + MIME subtype + + + ifdescription + &true; if there is a description string + + + description + Content description string + + + ifid + &true; if there is an identification string + + + id + Identification string + + + lines + Number of lines + + + bytes + Number of bytes + + + ifdisposition + &true; if there is a disposition string + + + disposition + Disposition string + + + ifdparameters + &true; if the dparameters array exists + + + dparameters + An array of objects where each object has an "attribute" and a + "value" property corresponding to the parameters on the + Content-disposition MIMEheader. + + + ifparameters + &true; if the parameters array exists + + + parameters + An array of objects where each object has an "attribute" and + a "value" property. + + + parts + An array of objects identical in structure to the top-level + object, each of which corresponds to a MIME body + part. + + + +
+
+ + + Primary body type + + + 0text + 1multipart + 2message + 3application + 4audio + 5image + 6video + 7other + + +
+
+ + + Transfer encodings + + + 07BIT + 18BIT + 2BINARY + 3BASE64 + 4QUOTED-PRINTABLE + 5OTHER + + +
+
+ + See also: imap_fetchbody. + +
+
- - - - imap_get_quota - - Retrieve the quota level settings, and usage statics per mailbox - - - - Description - - arrayimap_get_quota - resourceimap_stream - stringquota_root - - - Returns an array with integer values limit and usage for the given - mailbox. The value of limit represents the total amount of space - allowed for this mailbox. The usage value represents the mailboxes - current level of capacity. Will return &false; in the case of failure. - - - This function is currently only available to users of the c-client2000 - or greater library. - - - NOTE: For this function to work, the mail stream is required to be opened - as the mail-admin user. For a non-admin user version of this function, - please see the imap_get_quotaroot function of PHP. - - - imap_stream should be the value returned from - an imap_open call. NOTE: This stream is required - to be opened as the mail admin user for the get_quota function to work. - quota_root should normally be in the form of - user.name where name is the mailbox you wish to retrieve information - about. - - - - <function>imap_get_quota</function> example - + + + + imap_get_quota + Retrieve the quota level settings, and usage statics per mailbox + + + Description + + arrayimap_get_quota + resourceimap_stream + stringquota_root + + + Returns an array with integer values limit and usage for the given + mailbox. The value of limit represents the total amount of space + allowed for this mailbox. The usage value represents the mailboxes + current level of capacity. Will return &false; in the case of failure. + + + This function is currently only available to users of the c-client2000 + or greater library. + + + NOTE: For this function to work, the mail stream is required to be opened + as the mail-admin user. For a non-admin user version of this function, + please see the imap_get_quotaroot function of PHP. + + + imap_stream should be the value returned from + an imap_open call. NOTE: This stream is required + to be opened as the mail admin user for the get_quota function to work. + quota_root should normally be in the form of + user.name where name is the mailbox you wish to retrieve information + about. + + + + <function>imap_get_quota</function> example + ]]> - - - - - As of PHP 4.3, the function more properly reflects the - functionality as dictated by the RFC2087. - The array return value has changed to support an unlimited number of returned resources (i.e. - messages, or sub-folders) with each named resource receiving an individual - array key. Each key value then contains an another array with the usage - and limit values within it. The example below shows the updated returned - output. - - - For backwards compatibility reasons, the original access methods are - still available for use, although it is suggested to update. - - - - <function>imap_get_quota</function> 4.3 or greater - example - + + + + + As of PHP 4.3, the function more properly reflects the + functionality as dictated by the RFC2087. + The array return value has changed to support an unlimited number of returned resources (i.e. + messages, or sub-folders) with each named resource receiving an individual + array key. Each key value then contains an another array with the usage + and limit values within it. The example below shows the updated returned + output. + + + For backwards compatibility reasons, the original access methods are + still available for use, although it is suggested to update. + + + + <function>imap_get_quota</function> 4.3 or greater + example + ]]> - - - - - See also imap_open, - imap_set_quota and - imap_get_quotaroot. - - - + + + + + See also imap_open, + imap_set_quota and + imap_get_quotaroot. + + + - - - imap_get_quotaroot - - Retrieve the quota settings per user - - - - Description - - arrayimap_get_quotaroot - resourceimap_stream - stringquota_root - - - Returns an array of integer values pertaining to the specified user - mailbox. All values contain a key based upon the resource name, and a - corresponding array with the usage and limit values within. - - - The limit value represents the total amount of space - allowed for this user's total mailbox usage. The usage value represents - the user's current total mailbox capacity. This function will return - &false; in the case of call failure, and an array of information about - the connection upon an un-parsable response from the server. - - - This function is currently only available to users of the c-client2000 - or greater library. - - - imap_stream should be the value returned from - an imap_open call. This stream should be opened - as the user whose mailbox you wish to check. - quota_root should normally be in the form of - which mailbox (i.e. INBOX). - - - - <function>imap_get_quotaroot</function> example - + + + + imap_get_quotaroot + Retrieve the quota settings per user + + + Description + + arrayimap_get_quotaroot + resourceimap_stream + stringquota_root + + + Returns an array of integer values pertaining to the specified user + mailbox. All values contain a key based upon the resource name, and a + corresponding array with the usage and limit values within. + + + The limit value represents the total amount of space + allowed for this user's total mailbox usage. The usage value represents + the user's current total mailbox capacity. This function will return + &false; in the case of call failure, and an array of information about + the connection upon an un-parsable response from the server. + + + This function is currently only available to users of the c-client2000 + or greater library. + + + imap_stream should be the value returned from + an imap_open call. This stream should be opened + as the user whose mailbox you wish to check. + quota_root should normally be in the form of + which mailbox (i.e. INBOX). + + + + <function>imap_get_quotaroot</function> example + ]]> - - - - - See also imap_open, - imap_set_quota and - imap_get_quota. - - - + + + + + See also imap_open, + imap_set_quota and + imap_get_quota. + + + - - - imap_getacl - - Gets the ACL for a given mailbox - - - - Description - - arrayimap_getacl - resourcestream_id - stringmailbox - + + + + imap_getacl + Gets the ACL for a given mailbox + + + Description + + arrayimap_getacl + resourcestream_id + stringmailbox + - &warn.undocumented.func; - - This function is currently only available to users of the c-client2000 - or greater library. - - - See also imap_setacl. - - - + &warn.undocumented.func; + + This function is currently only available to users of the c-client2000 + or greater library. + + + See also imap_setacl. + + + - - - - imap_getmailboxes - - Read the list of mailboxes, returning detailed information on - each one - - - - Description - - arrayimap_getmailboxes - resourceimap_stream - stringref - stringpattern - - - Returns an array of objects containing mailbox information. Each - object has the attributes name, specifying - the full name of the mailbox; delimiter, - which is the hierarchy delimiter for the part of the hierarchy - 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. - - - - - - Mailbox names containing international Characters outside the - printable ASCII range will be encoded and may be decoded by - imap_utf7_decode. - - - ref should normally be just the server - specification as described in imap_open, and - pattern specifies where in the mailbox - hierarchy to start searching. If you want all mailboxes, pass - '*' for pattern. - - - There are two special characters you can pass as part of the - pattern: '*' and '%'. '*' means to return - all mailboxes. If you pass pattern as '*', - you will get a list of the entire mailbox hierarchy. '%' means to - return the current level only. '%' as the - 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. - - - - <function>imap_getmailboxes</function> example - + + + + imap_getmailboxes + Read the list of mailboxes, returning detailed information on each one + + + Description + + arrayimap_getmailboxes + resourceimap_stream + stringref + stringpattern + + + Returns an array of objects containing mailbox information. Each + object has the attributes name, specifying + the full name of the mailbox; delimiter, + which is the hierarchy delimiter for the part of the hierarchy + 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. + + + + + + Mailbox names containing international Characters outside the + printable ASCII range will be encoded and may be decoded by + imap_utf7_decode. + + + ref should normally be just the server + specification as described in imap_open, and + pattern specifies where in the mailbox + hierarchy to start searching. If you want all mailboxes, pass + '*' for pattern. + + + There are two special characters you can pass as part of the + pattern: '*' and '%'. '*' means to return + all mailboxes. If you pass pattern as '*', + you will get a list of the entire mailbox hierarchy. '%' means to + return the current level only. '%' as the + 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. + + + + <function>imap_getmailboxes</function> example + $val) { @@ -95,18 +91,18 @@ if (is_array($list)) { } else { echo "imap_getmailboxes failed: " . imap_last_error() . "\n"; } - + imap_close($mbox); ?> ]]> - - - - - See also imap_getsubscribed. - - - + + + + + See also imap_getsubscribed. + + + - - - - imap_getsubscribed - List all the subscribed mailboxes - - - Description - - arrayimap_getsubscribed - resourceimap_stream - stringref - stringpattern - - - This function is identical to - imap_getmailboxes, except that it only - returns mailboxes that the user is subscribed to. - - - + + + + imap_getsubscribed + List all the subscribed mailboxes + + + Description + + arrayimap_getsubscribed + resourceimap_stream + stringref + stringpattern + + + This function is identical to + imap_getmailboxes, except that it only + returns mailboxes that the user is subscribed to. + + + - + imap_header diff --git a/reference/imap/functions/imap-headerinfo.xml b/reference/imap/functions/imap-headerinfo.xml index b368763236..611a80199c 100644 --- a/reference/imap/functions/imap-headerinfo.xml +++ b/reference/imap/functions/imap-headerinfo.xml @@ -1,44 +1,43 @@ - - - - - imap_headerinfo - Read the header of the message - - - Description - - objectimap_headerinfo - resourceimap_stream - intmsg_number - intfromlength - intsubjectlength - stringdefaulthost - - - This function returns an object of various header elements. - - - - - remail, date, Date, subject, Subject, in_reply_to, message_id, - newsgroups, followup_to, references + + + + imap_headerinfo + Read the header of the message + + + Description + + objectimap_headerinfo + resourceimap_stream + intmsg_number + intfromlength + intsubjectlength + stringdefaulthost + + + This function returns an object of various header elements. + + + + + 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 + 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 @@ -48,67 +47,67 @@ Unseen == 'U' || Recent == 'N' toaddress (full to: line, up to 1024 characters) to[] (returns an array of objects from the To line, containing): - personal - adl - mailbox - host + personal + adl + mailbox + host fromaddress (full from: line, up to 1024 characters) from[] (returns an array of objects from the From line, containing): - personal - adl - mailbox - host + personal + adl + mailbox + host ccaddress (full cc: line, up to 1024 characters) cc[] (returns an array of objects from the Cc line, containing): - personal - adl - mailbox - host + personal + adl + mailbox + host bccaddress (full bcc line, up to 1024 characters) bcc[] (returns an array of objects from the Bcc line, containing): - personal - adl - mailbox - host + personal + adl + mailbox + host reply_toaddress (full reply_to: line, up to 1024 characters) reply_to[] (returns an array of objects from the Reply_to line, containing): - personal - adl - mailbox - host + personal + adl + mailbox + host senderaddress (full sender: line, up to 1024 characters) sender[] (returns an array of objects from the sender line, containing): - personal - adl - mailbox - host + personal + adl + mailbox + host return_path (full return-path: line, up to 1024 characters) return_path[] (returns an array of objects from the return_path line, containing): - personal - adl - mailbox - host + personal + adl + mailbox + host udate (mail message date in unix time) -fetchfrom (from line formatted to fit fromlength +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 - - - - Description - - arrayimap_headers - resourceimap_stream - - - Returns an array of string formatted with header info. One - element per mail message. - - - + + + + imap_headers + Returns headers for all messages in a mailbox + + + Description + + arrayimap_headers + resourceimap_stream + + + Returns an array of string formatted with header info. One + element per mail message. + + + - - - - imap_last_error - - This function returns the last IMAP error (if any) that occurred - during this page request - - - - Description - - stringimap_last_error - - - - This function returns the full text of the last IMAP error - 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. Returns &false; if no error messages are available. - - - See also: imap_errors. - - - + + + + imap_last_error + This function returns the last IMAP error (if any) that occurred during this page request + + + Description + + stringimap_last_error + + + + This function returns the full text of the last IMAP error + 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. Returns &false; if no error messages are available. + + + See also: imap_errors. + + + - - - imap_list - Read the list of mailboxes - - - Description - - arrayimap_list - resourceimap_stream - stringref - stringpattern - - - Returns an array containing the names of the mailboxes. - See imap_getmailboxes for a description - of ref and pattern. - - - - <function>imap_list</function> example - + + + + imap_list + Read the list of mailboxes + + + Description + + arrayimap_list + resourceimap_stream + stringref + stringpattern + + + Returns an array containing the names of the mailboxes. + See imap_getmailboxes for a description + of ref and pattern. + + + + <function>imap_list</function> example + ]]> - - - - - See also: imap_getmailboxes. - - - + + + + + See also: imap_getmailboxes. + + + - + imap_listmailbox diff --git a/reference/imap/functions/imap-listscan.xml b/reference/imap/functions/imap-listscan.xml index f5164e1020..6b3a5cc22e 100644 --- a/reference/imap/functions/imap-listscan.xml +++ b/reference/imap/functions/imap-listscan.xml @@ -1,37 +1,34 @@ - - - - imap_listscan - - Read the list of mailboxes, takes a string to search for in the - text of the mailbox - - - - Description - - arrayimap_listscan - resourceimap_stream - stringref - stringpattern - stringcontent - - - Returns an array containing the names of the mailboxes that have - content in the text of the mailbox. - - - This function is similar to imap_listmailbox, - but it will additionally check for the presence of the string - content inside the mailbox data. - - - See imap_getmailboxes for a description - of ref and pattern. - - - + + + + imap_listscan + Read the list of mailboxes, takes a string to search for in the text of the mailbox + + + Description + + arrayimap_listscan + resourceimap_stream + stringref + stringpattern + stringcontent + + + Returns an array containing the names of the mailboxes that have + content in the text of the mailbox. + + + This function is similar to imap_listmailbox, + but it will additionally check for the presence of the string + content inside the mailbox data. + + + See imap_getmailboxes for a description + of ref and pattern. + + + - + imap_listsubscribed diff --git a/reference/imap/functions/imap-lsub.xml b/reference/imap/functions/imap-lsub.xml index 617a7b0895..a23b9f7123 100644 --- a/reference/imap/functions/imap-lsub.xml +++ b/reference/imap/functions/imap-lsub.xml @@ -1,24 +1,24 @@ - - - - imap_lsub - List all the subscribed mailboxes - - - Description - - arrayimap_lsub - resourceimap_stream - stringref - stringpattern - - - Returns an array of all the mailboxes that you have - subscribed. - - - + + + + imap_lsub + List all the subscribed mailboxes + + + Description + + arrayimap_lsub + resourceimap_stream + stringref + stringpattern + + + Returns an array of all the mailboxes that you have + subscribed. + + + - - - - imap_mail_compose - - Create a MIME message based on given envelope and body sections - - - - Description - - stringimap_mail_compose - arrayenvelope - arraybody - - - - - - <function>imap_mail_compose</function> example - + + + + imap_mail_compose + Create a MIME message based on given envelope and body sections + + + Description + + stringimap_mail_compose + arrayenvelope + arraybody + + + + + + <function>imap_mail_compose</function> example + ]]> - - - - - + + + + + - - - - imap_mail_copy - Copy specified messages to a mailbox - - - Description - - boolimap_mail_copy - resourceimap_stream - stringmsglist - stringmbox - intoptions - - - Copies mail messages specified by msglist - to specified mailbox. &return.success;. - - - msglist is a range not just message - numbers (as described in RFC2060). - - - options is a bitmask of one or more of - - - - CP_UID - the sequence numbers contain UIDS - - - - - CP_MOVE - Delete the messages from - the current mailbox after copying - - - - - - See also imap_mail_move. - - - + + + + imap_mail_copy + Copy specified messages to a mailbox + + + Description + + boolimap_mail_copy + resourceimap_stream + stringmsglist + stringmbox + intoptions + + + Copies mail messages specified by msglist + to specified mailbox. &return.success;. + + + msglist is a range not just message + numbers (as described in RFC2060). + + + options is a bitmask of one or more of + + + + CP_UID - the sequence numbers contain UIDS + + + + + CP_MOVE - Delete the messages from + the current mailbox after copying + + + + + + See also imap_mail_move. + + + - - - - imap_mail_move - Move specified messages to a mailbox - - - Description - - boolimap_mail_move - resourceimap_stream - stringmsglist - stringmbox - intoptions - - - Moves mail messages specified by msglist - to specified mailbox mbox. &return.success;. - - - msglist is a range not just message numbers - (as described in RFC2060). - - - options is a bitmask and may contain the single option: - - - - CP_UID - the sequence numbers contain UIDS - - - - - - See also imap_mail_copy. - - - + + + + imap_mail_move + Move specified messages to a mailbox + + + Description + + boolimap_mail_move + resourceimap_stream + stringmsglist + stringmbox + intoptions + + + Moves mail messages specified by msglist + to specified mailbox mbox. &return.success;. + + + msglist is a range not just message numbers + (as described in RFC2060). + + + options is a bitmask and may contain the single option: + + + + CP_UID - the sequence numbers contain UIDS + + + + + + See also imap_mail_copy. + + + - - - - imap_mail - - Send an email message - - - - Description - - boolimap_mail - stringto - stringsubject - stringmessage - stringadditional_headers - stringcc - stringbcc - stringrpath - - - This function allows sending of emails with correct handling of - Cc and Bcc receivers. &return.success;. - - - The parameters to, cc - and bcc are all strings and are all parsed - as RFC822 address lists. - - - The receivers specified in bcc will get the - mail, but are excluded from the headers. - - - Use the rpath parameter to specify return path. - This is useful when using PHP as a mail client for multiple users. - - - + + + + imap_mail + Send an email message + + + Description + + boolimap_mail + stringto + stringsubject + stringmessage + stringadditional_headers + stringcc + stringbcc + stringrpath + + + This function allows sending of emails with correct handling of + Cc and Bcc receivers. &return.success;. + + + The parameters to, cc + and bcc are all strings and are all parsed + as RFC822 address lists. + + + The receivers specified in bcc will get the + mail, but are excluded from the headers. + + + Use the rpath parameter to specify return path. + This is useful when using PHP as a mail client for multiple users. + + + - - - - imap_mailboxmsginfo - Get information about the current mailbox - - - Description - - objectimap_mailboxmsginfo - resourceimap_stream - - - Returns information about the current mailbox. Returns &false; on - failure. - - - The imap_mailboxmsginfo function checks the - current mailbox status on the server. It is similar to - imap_status, but will additionally sum up the - size of all messages in the mailbox, which will take some additional - time to execute. It returns the information - in an object with following properties. - - - - Mailbox properties - - - - Date - date of last change - - - Driver - driver - - - Mailbox - name of the mailbox - - - Nmsgs - number of messages - - - Recent - number of recent messages - - - Unread - number of unread messages - - - Deleted - number of deleted messages - - - Size - mailbox size - - - -
-
- - - <function>imap_mailboxmsginfo</function> example - + + + + imap_mailboxmsginfo + Get information about the current mailbox + + + Description + + objectimap_mailboxmsginfo + resourceimap_stream + + + Returns information about the current mailbox. Returns &false; on + failure. + + + The imap_mailboxmsginfo function checks the + current mailbox status on the server. It is similar to + imap_status, but will additionally sum up the + size of all messages in the mailbox, which will take some additional + time to execute. It returns the information + in an object with following properties. + + + + Mailbox properties + + + + Date + date of last change + + + Driver + driver + + + Mailbox + name of the mailbox + + + Nmsgs + number of messages + + + Recent + number of recent messages + + + Unread + number of unread messages + + + Deleted + number of deleted messages + + + Size + mailbox size + + + +
+
+ + + <function>imap_mailboxmsginfo</function> example + Date . "
\n" ; echo "Driver: " . $check->Driver . "
\n" ; @@ -89,16 +88,16 @@ if ($check) { } else { echo "imap_check() failed: " . imap_last_error() . "
\n"; } - + imap_close($mbox); ?> ]]> -
-
-
-
-
+
+
+
+
+
- - - - imap_mime_header_decode - Decode MIME header elements - - - Description - - arrayimap_mime_header_decode - stringtext - - - imap_mime_header_decode function decodes - MIME message header extensions that are non ASCII text - (see RFC2047). - The decoded elements are returned in an array of objects, - where each object has two properties, "charset" and "text". - If the element hasn't been encoded, and in other words is in - plain US-ASCII,the "charset" property of that element is set to - "default". - - - - <function>imap_mime_header_decode</function> example - + + + + imap_mime_header_decode + Decode MIME header elements + + + Description + + arrayimap_mime_header_decode + stringtext + + + imap_mime_header_decode function decodes + MIME message header extensions that are non ASCII text + (see RFC2047). + The decoded elements are returned in an array of objects, + where each object has two properties, "charset" and "text". + If the element hasn't been encoded, and in other words is in + plain US-ASCII,the "charset" property of that element is set to + "default". + + + + <function>imap_mime_header_decode</function> example + "; @@ -37,19 +36,19 @@ for ($i=0; $i ]]> - - - - - In the above example we would have two elements, whereas the first - element had previously been encoded with ISO-8859-1, and the second - element would be plain US-ASCII. - - - See also imap_utf8. - - - + + + + + In the above example we would have two elements, whereas the first + element had previously been encoded with ISO-8859-1, and the second + element would be plain US-ASCII. + + + See also imap_utf8. + + + - - - - imap_msgno - - This function returns the message sequence number for the given - UID - - - - Description - - intimap_msgno - resourceimap_stream - intuid - - - This function returns the message sequence number for the given - uid. It is the inverse of - imap_uid. - - - See also imap_uid. - - - + + + + imap_msgno + This function returns the message sequence number for the given UID + + + Description + + intimap_msgno + resourceimap_stream + intuid + + + This function returns the message sequence number for the given + uid. It is the inverse of + imap_uid. + + + See also imap_uid. + + + - - - - imap_num_msg - - Gives the number of messages in the current mailbox - - - - Description - - intimap_num_msg - resourceimap_stream - - - Return the number of messages in the current mailbox. - - - See also: imap_num_recent and - imap_status. - - - + + + + imap_num_msg + Gives the number of messages in the current mailbox + + + Description + + intimap_num_msg + resourceimap_stream + + + Return the number of messages in the current mailbox. + + + See also: imap_num_recent and + imap_status. + + + - - - - imap_num_recent - Gives the number of recent messages in current - mailbox - - - Description - - intimap_num_recent - resourceimap_stream - - - Returns the number of recent messages in the current mailbox. - - - See also: imap_num_msg and - imap_status. - - - + + + + imap_num_recent + Gives the number of recent messages in current + mailbox + + + Description + + intimap_num_recent + resourceimap_stream + + + Returns the number of recent messages in the current mailbox. + + + See also: imap_num_msg and + imap_status. + + + - - - - imap_open - Open an IMAP stream to a mailbox - - - Description - - resourceimap_open - stringmailbox - stringusername - stringpassword - intoptions - - - Returns an IMAP stream on success and &false; on error. This - function can also be used to open streams to POP3 and NNTP - servers, but some functions and features are only available - on IMAP servers. - - - A mailbox name consists of a server part and a mailbox path on - this server. The special name INBOX stands for the current users - personal mailbox. The server part, which is enclosed in '{' and - '}', consists of the servers name or ip address, an optional port - (prefixed by ':'), and an optional protocol specification (prefixed - by '/'). The server part is mandatory in all mailbox - parameters. Mailbox names that contain international characters - besides those in the printable ASCII space have to be encoded - with imap_utf7_encode. - - - All names which start with { are remote names, and are - in the form "{" remote_system_name [":" port] [flags] "}" - [mailbox_name] where: - - - - remote_system_name - Internet domain name or - bracketed IP address of server. - - - - - port - optional TCP port number, default is the - default port for that service - - - - - flags - optional flags, see following table. - - - - - mailbox_name - remote mailbox name, default is INBOX - - - - - - - Optional flags for names - - - - Flag - Description - - - - - /service=service - mailbox access service, default is "imap" - - - /user=user - remote user name for login on the server - - - /authuser=user - remote authentication user; if specified this is the user name - whose password is used (e.g. administrator) - - - /anonymous - remote access as anonymous user - - - /debug - record protocol telemetry in application's debug log - - - /secure - do not transmit a plaintext password over the network - - - /imap, /imap2, - /imap2bis, /imap4, - /imap4rev1 - equivalent to /service=imap - - - /pop3 - equivalent to /service=pop3 - - - /nntp - equivalent to /service=nntp - - - /norsh - do not use rsh or ssh to establish a preauthenticated IMAP - session - - - /ssl - use the Secure Socket Layer to encrypt the session - - - /validate-cert - validate certificates from TLS/SSL server (this is the default - behavior) - - - /novalidate-cert - do not validate certificates from TLS/SSL server, needed if - server uses self-signed certificates - - - /tls - force use of start-TLS to encrypt the session, and reject - connection to servers that do not support it - - - /notls - do not do start-TLS to encrypt the session, even with servers - that support it - - - /readonly - request read-only mailbox open (IMAP only; ignored on NNTP, and - an error with SMTP and POP3) - - - -
-
- - The options are a bit mask with one or more of the following: - - - - OP_READONLY - Open mailbox read-only - - - - - OP_ANONYMOUS - Don't use or update a - .newsrc for news (NNTP only) - - - - - OP_HALFOPEN - For IMAP and NNTP names, open a connection but - don't open a mailbox. - - - - - CL_EXPUNGE - Expunge mailbox automatically upon mailbox close - (see also imap_delete and - imap_expunge) - - - - - OP_DEBUG - Debug protocol negotiations - - - - - OP_SHORTCACHE - Short (elt-only) caching - - - - - OP_SILENT - Don't pass up events (internal use) - - - - - OP_PROTOTYPE - Return driver prototype - - - - - OP_EXPUNGE - Silently expunge recycle stream - - - - - OP_SECURE - Don't do non-secure authentication - - - - - - - Different use of <function>imap_open</function> - + + + + imap_open + Open an IMAP stream to a mailbox + + + Description + + resourceimap_open + stringmailbox + stringusername + stringpassword + intoptions + + + Returns an IMAP stream on success and &false; on error. This + function can also be used to open streams to POP3 and NNTP + servers, but some functions and features are only available + on IMAP servers. + + + A mailbox name consists of a server part and a mailbox path on + this server. The special name INBOX stands for the current users + personal mailbox. The server part, which is enclosed in '{' and + '}', consists of the servers name or ip address, an optional port + (prefixed by ':'), and an optional protocol specification (prefixed + by '/'). The server part is mandatory in all mailbox + parameters. Mailbox names that contain international characters + besides those in the printable ASCII space have to be encoded + with imap_utf7_encode. + + + All names which start with { are remote names, and are + in the form "{" remote_system_name [":" port] [flags] "}" + [mailbox_name] where: + + + + remote_system_name - Internet domain name or + bracketed IP address of server. + + + + + port - optional TCP port number, default is the + default port for that service + + + + + flags - optional flags, see following table. + + + + + mailbox_name - remote mailbox name, default is INBOX + + + + + + + Optional flags for names + + + + Flag + Description + + + + + /service=service + mailbox access service, default is "imap" + + + /user=user + remote user name for login on the server + + + /authuser=user + remote authentication user; if specified this is the user name + whose password is used (e.g. administrator) + + + /anonymous + remote access as anonymous user + + + /debug + record protocol telemetry in application's debug log + + + /secure + do not transmit a plaintext password over the network + + + /imap, /imap2, + /imap2bis, /imap4, + /imap4rev1 + equivalent to /service=imap + + + /pop3 + equivalent to /service=pop3 + + + /nntp + equivalent to /service=nntp + + + /norsh + do not use rsh or ssh to establish a preauthenticated IMAP + session + + + /ssl + use the Secure Socket Layer to encrypt the session + + + /validate-cert + validate certificates from TLS/SSL server (this is the default + behavior) + + + /novalidate-cert + do not validate certificates from TLS/SSL server, needed if + server uses self-signed certificates + + + /tls + force use of start-TLS to encrypt the session, and reject + connection to servers that do not support it + + + /notls + do not do start-TLS to encrypt the session, even with servers + that support it + + + /readonly + request read-only mailbox open (IMAP only; ignored on NNTP, and + an error with SMTP and POP3) + + + +
+
+ + The options are a bit mask with one or more of the following: + + + + OP_READONLY - Open mailbox read-only + + + + + OP_ANONYMOUS - Don't use or update a + .newsrc for news (NNTP only) + + + + + OP_HALFOPEN - For IMAP and NNTP names, open a connection but + don't open a mailbox. + + + + + CL_EXPUNGE - Expunge mailbox automatically upon mailbox close + (see also imap_delete and + imap_expunge) + + + + + OP_DEBUG - Debug protocol negotiations + + + + + OP_SHORTCACHE - Short (elt-only) caching + + + + + OP_SILENT - Don't pass up events (internal use) + + + + + OP_PROTOTYPE - Return driver prototype + + + + + OP_EXPUNGE - Silently expunge recycle stream + + + + + OP_SECURE - Don't do non-secure authentication + + + + + + + Different use of <function>imap_open</function> + ]]> - - - - - - <function>imap_open</function> example - + + + + + + <function>imap_open</function> example + ]]> - - - -
-
+
+
+
+
+
- - - - imap_ping - Check if the IMAP stream is still active - - - Description - - boolimap_ping - resourceimap_stream - - - Returns &true; if the stream is still alive, &false; otherwise. - - - imap_ping pings the stream to see if it's 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. - - - - <function>imap_ping</function> Example - + + + + imap_ping + Check if the IMAP stream is still active + + + Description + + boolimap_ping + resourceimap_stream + + + Returns &true; if the stream is still alive, &false; otherwise. + + + imap_ping pings the stream to see if it's 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. + + + + <function>imap_ping</function> Example + ]]> - - - - - + + + + + - - - - imap_qprint - Convert a quoted-printable string to an 8 bit - string - - - Description - - stringimap_qprint - stringstring - - - Convert a quoted-printable string to an 8 bit string (according - to RFC2045, section - 6.7). - - - See also imap_8bit. - - - + + + + imap_qprint + Convert a quoted-printable string to an 8 bit + string + + + Description + + stringimap_qprint + stringstring + + + Convert a quoted-printable string to an 8 bit string (according + to RFC2045, section + 6.7). + + + See also imap_8bit. + + + - - - - imap_renamemailbox - Rename an old mailbox to new mailbox - - - Description - - boolimap_renamemailbox - resourceimap_stream - stringold_mbox - stringnew_mbox - - - This function renames on old mailbox to new mailbox (see - imap_open for the format of - mbox names). - - - &return.success; - - - See also imap_createmailbox, - imap_deletemailbox, and - imap_open for the format of - mbox. - - - + + + + imap_renamemailbox + Rename an old mailbox to new mailbox + + + Description + + boolimap_renamemailbox + resourceimap_stream + stringold_mbox + stringnew_mbox + + + This function renames on old mailbox to new mailbox (see + imap_open for the format of + mbox names). + + + &return.success; + + + See also imap_createmailbox, + imap_deletemailbox, and + imap_open for the format of + mbox. + + + - - - - imap_reopen - Reopen IMAP stream to new mailbox - - - Description - - boolimap_reopen - resourceimap_stream - stringmailbox - intoptions - - - This function reopens the specified stream to a new - mailbox on an IMAP or NNTP server. - - - The options are a bit mask with one or more of the following: - - - - OP_READONLY - Open mailbox read-only - - - - - OP_ANONYMOUS - Don't use or update a - .newsrc for news (NNTP only) - - - - - OP_HALFOPEN - For IMAP and NNTP names, open a connection but - don't open a mailbox. - - - - - CL_EXPUNGE - Expunge mailbox automatically upon mailbox close - (see also imap_delete and - imap_expunge) - - - - - - &return.success; - - - <function>imap_reopen</function> example - + + + + imap_reopen + Reopen IMAP stream to new mailbox + + + Description + + boolimap_reopen + resourceimap_stream + stringmailbox + intoptions + + + This function reopens the specified stream to a new + mailbox on an IMAP or NNTP server. + + + The options are a bit mask with one or more of the following: + + + + OP_READONLY - Open mailbox read-only + + + + + OP_ANONYMOUS - Don't use or update a + .newsrc for news (NNTP only) + + + + + OP_HALFOPEN - For IMAP and NNTP names, open a connection but + don't open a mailbox. + + + + + CL_EXPUNGE - Expunge mailbox automatically upon mailbox close + (see also imap_delete and + imap_expunge) + + + + + + &return.success; + + + <function>imap_reopen</function> example + ]]> - - - + + + - +
- - - - imap_rfc822_parse_adrlist - Parses an address string - - - Description - - arrayimap_rfc822_parse_adrlist - stringaddress - stringdefault_host - - - This function parses the address string as defined in - RFC2822 and - for each address, returns an array of objects. - The objects properties are: - - - - - - mailbox - the mailbox name (username) - - - - - host - the host name - - - - - personal - the personal name - - - - - adl - at domain source route - - - - - - - <function>imap_rfc822_parse_adrlist</function> example - + + + + imap_rfc822_parse_adrlist + Parses an address string + + + Description + + arrayimap_rfc822_parse_adrlist + stringaddress + stringdefault_host + + + This function parses the address string as defined in + RFC2822 and + for each address, returns an array of objects. + The objects properties are: + + + + + + mailbox - the mailbox name (username) + + + + + host - the host name + + + + + personal - the personal name + + + + + adl - at domain source route + + + + + + + <function>imap_rfc822_parse_adrlist</function> example + mailbox . "
\n"; echo "host : " . $val->host . "
\n"; echo "personal: " . $val->personal . "
\n"; echo "adl : " . $val->adl . "
\n"; -} +} ?> ]]> -
-
-
-
-
+
+
+
+
+
- - - - imap_rfc822_parse_headers - Parse mail headers from a string - - - Description - - objectimap_rfc822_parse_headers - stringheaders - stringdefaulthost - - - This function returns an object of various header elements, - similar to imap_header, except without the - flags and other elements that come from the IMAP server. - - - + + + + imap_rfc822_parse_headers + Parse mail headers from a string + + + Description + + objectimap_rfc822_parse_headers + stringheaders + stringdefaulthost + + + This function returns an object of various header elements, + similar to imap_header, except without the + flags and other elements that come from the IMAP server. + + + - - - - imap_rfc822_write_address - - Returns a properly formatted email address given the mailbox, - host, and personal info - - - - Description - - stringimap_rfc822_write_address - stringmailbox - stringhost - stringpersonal - - - Returns a properly formatted email address as defined in - RFC2822 - given the mailbox, host, - and personal info. - - - - <function>imap_rfc822_write_address</function> example - + + + + imap_rfc822_write_address + Returns a properly formatted email address given the mailbox, host, and personal info + + + Description + + stringimap_rfc822_write_address + stringmailbox + stringhost + stringpersonal + + + Returns a properly formatted email address as defined in + RFC2822 + given the mailbox, host, + and personal info. + + + + <function>imap_rfc822_write_address</function> example + ]]> - - - - - + + + + + - + imap_scanmailbox diff --git a/reference/imap/functions/imap-search.xml b/reference/imap/functions/imap-search.xml index f574c1643a..edf740bc07 100644 --- a/reference/imap/functions/imap-search.xml +++ b/reference/imap/functions/imap-search.xml @@ -1,170 +1,166 @@ - - - - - imap_search - - This function returns an array of messages matching the given - search criteria - - - - Description - - arrayimap_search - resourceimap_stream - stringcriteria - intoptions - stringcharset - - - 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 (e.g. 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 - - - - - - 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 incomplete or - inaccurate (see also RFC2060, section 6.4.4). - - - Valid values for flags are SE_UID, which causes the returned - array to contain UIDs instead of messages sequence numbers. - - - Parameter charset was added in PHP 4.3.3. - - - + + + + imap_search + This function returns an array of messages matching the given search criteria + + + Description + + arrayimap_search + resourceimap_stream + stringcriteria + intoptions + stringcharset + + + 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 (e.g. 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 + + + + + + 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 incomplete or + inaccurate (see also RFC2060, section 6.4.4). + + + Valid values for flags are SE_UID, which causes the returned + array to contain UIDs instead of messages sequence numbers. + + + Parameter charset was added in PHP 4.3.3. + + + - - - - imap_set_quota - Sets a quota for a given mailbox - - - Description - - boolimap_set_quota - resourceimap_stream - stringquota_root - intquota_limit - - - Sets an upper limit quota on a per mailbox basis. This function - requires the imap_stream to have been opened - as the mail administrator account. It will not work if opened as - any other user. - - - This function is currently only available to users of the c-client2000 - or greater library. - - - imap_stream is the stream pointer returned from - a imap_open call. This stream must be opened as - the mail administrator, other wise this function will fail. - quota_root is the mailbox to have a quota set. This - should follow the IMAP standard format for a mailbox, 'user.name'. - quota_limit is the maximum size (in KB) for - the quota_root. - - - Returns &true; on success and &false; on error. - - - - <function>imap_set_quota</function> example - + + + + imap_set_quota + Sets a quota for a given mailbox + + + Description + + boolimap_set_quota + resourceimap_stream + stringquota_root + intquota_limit + + + Sets an upper limit quota on a per mailbox basis. This function + requires the imap_stream to have been opened + as the mail administrator account. It will not work if opened as + any other user. + + + This function is currently only available to users of the c-client2000 + or greater library. + + + imap_stream is the stream pointer returned from + a imap_open call. This stream must be opened as + the mail administrator, other wise this function will fail. + quota_root is the mailbox to have a quota set. This + should follow the IMAP standard format for a mailbox, 'user.name'. + quota_limit is the maximum size (in KB) for + the quota_root. + + + Returns &true; on success and &false; on error. + + + + <function>imap_set_quota</function> example + ]]> - - - - - See also imap_open and - imap_get_quota. - - - + + + + + See also imap_open and + imap_get_quota. + + + - - - - imap_setacl - - Sets the ACL for a giving mailbox - - - - Description - - boolimap_setacl - resourcestream_id - stringmailbox - stringid - stringrights - - - &warn.undocumented.func; - - - This function is currently only available to users of the c-client2000 - or greater library. - - - See also imap_getacl. - - - + + + + imap_setacl + Sets the ACL for a giving mailbox + + + Description + + boolimap_setacl + resourcestream_id + stringmailbox + stringid + stringrights + + + &warn.undocumented.func; + + + This function is currently only available to users of the c-client2000 + or greater library. + + + See also imap_getacl. + + + - - - - imap_setflag_full - Sets flags on messages - - - Description - - boolimap_setflag_full - resourcestream - stringsequence - stringflag - stringoptions - - - 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", and "\\Draft" (as defined - by RFC2060). - - - options are a bit mask and may contain - the single option: - - - - ST_UID - The sequence argument contains UIDs - instead of sequence numbers - - - - - - - <function>imap_setflag_full</function> example - + + + + imap_setflag_full + Sets flags on messages + + + Description + + boolimap_setflag_full + resourcestream + stringsequence + stringflag + stringoptions + + + 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", and "\\Draft" (as defined + by RFC2060). + + + options are a bit mask and may contain + the single option: + + + + ST_UID - The sequence argument contains UIDs + instead of sequence numbers + + + + + + + <function>imap_setflag_full</function> example + ]]> - - - - - See also: imap_clearflag_full. - - - + + + + + See also: imap_clearflag_full. + + + - - - - imap_sort - Sort an array of message headers - - - Description - - arrayimap_sort - resourcestream - intcriteria - intreverse - intoptions - stringsearch_criteria - stringcharset - - - Returns an array of message numbers sorted by the given - parameters. - - - Reverse 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 - - - - - - The flags are a bitmask of one or more of the following: - - - - SE_UID - Return UIDs instead of sequence numbers - - - - - SE_NOPREFETCH - Don't prefetch searched messages - - - - - - Parameter charset was added in PHP 4.3.3. - - - + + + + imap_sort + Sort an array of message headers + + + Description + + arrayimap_sort + resourcestream + intcriteria + intreverse + intoptions + stringsearch_criteria + stringcharset + + + Returns an array of message numbers sorted by the given + parameters. + + + Reverse 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 + + + + + + The flags are a bitmask of one or more of the following: + + + + SE_UID - Return UIDs instead of sequence numbers + + + + + SE_NOPREFETCH - Don't prefetch searched messages + + + + + + Parameter charset was added in PHP 4.3.3. + + + - - - - imap_status - - This function returns status information on a mailbox other than - the current one - - - - Description - - objectimap_status - resourceimap_stream - stringmailbox - intoptions - - - 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. - - - - <function>imap_status</function> example - + + + + imap_status + This function returns status information on a mailbox other than the current one + + + Description + + objectimap_status + resourceimap_stream + stringmailbox + intoptions + + + 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. + + + + <function>imap_status</function> example + messages . "
\n"; echo "Recent: " . $status->recent . "
\n"; echo "Unseen: " . $status->unseen . "
\n"; echo "UIDnext: " . $status->uidnext . "
\n"; - echo "UIDvalidity:" . $status->uidvalidity . "
\n"; + echo "UIDvalidity:" . $status->uidvalidity . "
\n"; } else { echo "imap_status failed: " . imap_last_error() . "\n"; } @@ -85,11 +81,11 @@ if ($status) { imap_close($mbox); ?> ]]> -
-
-
-
-
+
+
+
+
+
- - - - imap_subscribe - Subscribe to a mailbox - - - Description - - boolimap_subscribe - resourceimap_stream - stringmbox - - - Subscribe to a new mailbox. - - - &return.success; - - - See also: imap_unsubscribe. - - - + + + + imap_subscribe + Subscribe to a mailbox + + + Description + + boolimap_subscribe + resourceimap_stream + stringmbox + + + Subscribe to a new mailbox. + + + &return.success; + + + See also: imap_unsubscribe. + + + - - - - imap_thread - - Returns a tree of threaded message - - - - Description - - arrayimap_thread - resourcestream_id - intoptions - - - imap_thread returns an associative array containing - a tree of messages threaded by REFERENCES, or &false; - on error. - - - Every message in the current mailbox will be represented by three entries - in the resulting array: - - - $thread["XX.num"] - current message number - - - $thread["XX.next"] - - - $thread["XX.branch"] - - - - - - <function>imap_thread</function> Example - + + + + imap_thread + Returns a tree of threaded message + + + Description + + arrayimap_thread + resourcestream_id + intoptions + + + imap_thread returns an associative array containing + a tree of messages threaded by REFERENCES, or &false; + on error. + + + Every message in the current mailbox will be represented by three entries + in the resulting array: + + + $thread["XX.num"] - current message number + + + $thread["XX.next"] + + + $thread["XX.branch"] + + + + + + <function>imap_thread</function> Example + ]]> - - - - - + + + + + - - - imap_timeout - - Set or fetch imap timeout - - - - Description - - mixedimap_timeout - inttimeout_type - inttimeout - + + + + imap_timeout + Set or fetch imap timeout + + + Description + + mixedimap_timeout + inttimeout_type + inttimeout + - &warn.undocumented.func; + &warn.undocumented.func; - - + + - - - - imap_uid - - This function returns the UID for the given message sequence - number - - - - Description - - intimap_uid - resourceimap_stream - intmsgno - - - This function returns the UID for the given message sequence - number. An UID is a unique identifier that will not change over - time while a message sequence number may change whenever the - content of the mailbox changes. This function is the inverse of - imap_msgno. - - - - This is not supported by POP3 mailboxes. - - - - See also: imap_msgno. - - - + + + + imap_uid + This function returns the UID for the given message sequence number + + + Description + + intimap_uid + resourceimap_stream + intmsgno + + + This function returns the UID for the given message sequence + number. An UID is a unique identifier that will not change over + time while a message sequence number may change whenever the + content of the mailbox changes. This function is the inverse of + imap_msgno. + + + + This is not supported by POP3 mailboxes. + + + + See also: imap_msgno. + + + - - - - imap_undelete - - Unmark the message which is marked deleted - - - - Description - - boolimap_undelete - resourceimap_stream - intmsg_number - intflags - - - This function removes the deletion flag for a specified message, - which is set by imap_delete or - imap_mail_move. - - - &return.success; - - - See also: - imap_delete, and - imap_mail_move. - - - + + + + imap_undelete + Unmark the message which is marked deleted + + + Description + + boolimap_undelete + resourceimap_stream + intmsg_number + intflags + + + This function removes the deletion flag for a specified message, + which is set by imap_delete or + imap_mail_move. + + + &return.success; + + + See also: + imap_delete, and + imap_mail_move. + + + - - - - imap_unsubscribe - Unsubscribe from a mailbox - - - Description - - boolimap_unsubscribe - stringimap_stream - stringmbox - - - Unsubscribe from a specified mailbox. - - - &return.success; - - - See also: imap_subscribe. - - - + + + + imap_unsubscribe + Unsubscribe from a mailbox + + + Description + + boolimap_unsubscribe + stringimap_stream + stringmbox + + + Unsubscribe from a specified mailbox. + + + &return.success; + + + See also: imap_subscribe. + + + - - - - imap_utf7_decode - - Decodes a modified UTF-7 encoded string - - - - Description - - stringimap_utf7_decode - stringtext - - - Decodes modified UTF-7 text into ISO-8859-1 string. - - - Returns a string that is encoded in ISO-8859-1 and consists of the same - sequence of characters in text, or &false; - if text contains invalid modified UTF-7 sequence - or text contains a character that is not part of - ISO-8859-1 character set. - - - This function is needed to decode mailbox names that contain certain - characters which are not in range of printable ASCII characters. - - - The modified UTF-7 encoding is defined in - RFC 2060, section - 5.1.3 (original UTF-7 was defined in RFC1642). - - - See also: imap_utf7_encode. - - - + + + + imap_utf7_decode + Decodes a modified UTF-7 encoded string + + + Description + + stringimap_utf7_decode + stringtext + + + Decodes modified UTF-7 text into ISO-8859-1 string. + + + Returns a string that is encoded in ISO-8859-1 and consists of the same + sequence of characters in text, or &false; + if text contains invalid modified UTF-7 sequence + or text contains a character that is not part of + ISO-8859-1 character set. + + + This function is needed to decode mailbox names that contain certain + characters which are not in range of printable ASCII characters. + + + The modified UTF-7 encoding is defined in + RFC 2060, section + 5.1.3 (original UTF-7 was defined in RFC1642). + + + See also: imap_utf7_encode. + + + - - - - imap_utf7_encode - - Converts ISO-8859-1 string to modified UTF-7 text - - - - Description - - stringimap_utf7_encode - stringdata - - - Converts data to modified UTF-7 - text. Note that data is expected to be - encoded in ISO-8859-1. - - - This is needed to encode mailbox names that contain certain - characters which are not in range of printable ASCII characters. - - - The modified UTF-7 encoding is defined in RFC 2060, section 5.1.3 - (original UTF-7 was defined in RFC1642). - - - See also: imap_utf7_decode. - - - + + + + imap_utf7_encode + Converts ISO-8859-1 string to modified UTF-7 text + + + Description + + stringimap_utf7_encode + stringdata + + + Converts data to modified UTF-7 + text. Note that data is expected to be + encoded in ISO-8859-1. + + + This is needed to encode mailbox names that contain certain + characters which are not in range of printable ASCII characters. + + + The modified UTF-7 encoding is defined in RFC 2060, section 5.1.3 + (original UTF-7 was defined in RFC1642). + + + See also: imap_utf7_decode. + + + - - - - imap_utf8 - - Converts MIME-encoded text to UTF-8 - - - - Description - - stringimap_utf8 - stringmime_encoded_text - - - Converts the given mime_encoded_text to - UTF-8. MIME encoding method and the UTF-8 specification are described in - RFC2047 and - RFC2044 respectively. - - - See also imap_mime_header_decode. - - - + + + + imap_utf8 + Converts MIME-encoded text to UTF-8 + + + Description + + stringimap_utf8 + stringmime_encoded_text + + + Converts the given mime_encoded_text to + UTF-8. MIME encoding method and the UTF-8 specification are described in + RFC2047 and + RFC2044 respectively. + + + See also imap_mime_header_decode. + + +