echo "信件" . $rec->mail_list[$i][num] . ",大小:" . $rec->mail_list[$i][size] . "<BR>"; $rec->getmail($rec->mail_list[$i][num]); $decoder->decode($rec->head, $rec->body); echo "<h3>邮件头的内容:</h3><br>"; echo $decoder->from_name . "(" . $decoder->from_mail . ") 于" . date("Y-m-d H:i:s", $decoder->mail_time) . " 发给" . $decoder->to_name . "(" . $decoder->to_mail . ")"; echo "\n<br>抄送:"; if ($decoder->cc_to) { echo $decoder->cc_to; } else { echo "无"; } echo "\n<br>主题:" . $decoder->subject; echo "\n<br>回复到:" . $decoder->reply_to; echo "<h3>邮件正文 :</h3><BR>"; echo "正文类型:" . $decoder->body_type; echo "<br>正文各内容:"; for ($j = 0; $j < count($decoder->body); $j++) { echo "\n<br>类型:" . $decoder->body[$j][type]; echo "\n<br>名称:" . $decoder->body[$j][name]; echo "\n<br>大小:" . $decoder->body[$j][size]; echo "\n<br>content_id:" . $decoder->body[$j][content_id]; echo "\n<br>正文字符集" . $decoder->body[$j][char_set]; echo "<pre>"; echo "正文内容:" . $decoder->body[$j][content]; echo "</pre>"; } //$rec->dele($i); } } $rec->close();