我是php的新手.我想向某人发送电子邮件,然后我需要检查是否可以收到此邮件.我怎么做?希望你们明白我的问题;).提前致谢.渣
这是一个非常棘手的问题.唯一真正的方法是让PHP监控收件箱以检查您可能会收到的"无法投递的消息"通知.如果您真的想继续使用它,请查看用于PHP的POP3连接器.像这样:http://pecl.php.net/package/POP3
if (strpos(strtolower($subject), 'undeliverable') !== false){
//do whatever you want with the address that couldn't be reached
}
Run Code Online (Sandbox Code Playgroud)
从技术上讲,你不需要为POP3编译PHP扩展(特别是如果你是PHP新手)...你可以通过打开套接字和讲邮件服务器来连接和阅读消息:http: //www.adamsinfo.com/一,最基本的PHP-POP3-示例/
当然退房http://mailgun.net/,http://sendgrid.com/和http://postmarkapp.com/.