imap_fetchstructure
獲取某信件的結構信息。
語法: array imap_fetchstructure(int imap_stream, int msg_number);
返回值: 數組
函數種類: 網絡繫統
本函數可讀取指定信件的相關信息。參數 imap_stream 為 IMAP 的代號。參數 msg_number 為信件的序號。返回的信息為數組的方式,各元素的內容見下表
元素名稱 | 類型 |
type | 整數 (Integer) |
encoding | 整數 (Integer) |
ifsubtype | 布爾 (Boolean) |
subtype | 字符串 (String) |
ifdescription | 布爾 (Boolean) |
description | 字符串 (String) |
ifid | 布爾 (Boolean) |
id | 字符串 (String) |
lines | 整數 (Integer) |
bytes | 整數 (Integer) |
ifparameters | 布爾 (Boolean) |
其中 type 元素的值代表的意義如下
值 | 代表意義 |
0 | 文字 text |
1 | 復合 multipart |
2 | 信息 message |
3 | 程序 application |
4 | 聲音 audio |
5 | 圖形 image |
6 | 影像 video |
7 | 其它 other |
而 encoding 值代表的意義如下
值 | 代表意義 |
0 | 七位 (7 bit) |
1 | 八位 (8 bit) |
2 | 二進位 (binary) |
3 | BASE64 編碼 |
4 | QP 編碼 (QuotedPrintable) |
5 | 其它 |
整理: 夕垌菪姬 (天地JPLOP)
|