$mailServer=\"大众mail.staff.sina.com.cn\公众;

$mailLink=\公众{mail.staff.sina.com.cn:995/pop3/ssl}INBOX\"大众;

$mailUser = 'zekai';

phpimapmailPHP若何应用imap协定吸收邮件 Python

$mailPass = 'password';

$stream = @imap_open($mailLink,$mailUser,$mailPass);

$totalrows = imap_num_msg($stream);

var_dump($totalrows);

for($i=$totalrows;$i>=$totalrows;$i--)

{

$headers = @imap_header($stream, $i);

$mail_header= imap_headerinfo($stream, $i);

var_dump ($mail_header);die;

$subject = $mail_header->subject;

$subject=decode_mime($subject);

echo $subject;die;

}

?>

以上便是【PHP】如何利用imap协议吸收邮件的详细内容,更多请关注其它干系文章!

更多技巧请《转发 + 关注》哦!