【发布时间】:2012-04-28 07:24:31
【问题描述】:
我需要知道为什么我的电子邮件没有在收件箱中发送并且无法附加文件
这是我的标题和消息
标题
MIME-Version: 1.0; \r\nContent-Type: multipart/mixed; boundary="PHP-mixed-MIME_BOUNDARY_MESSAGE_PARTS";Return-Path:mx@mozhl.com;\r\nOrganization: Shbkat.com;\r\n\r\n From: mx@shbkat.com; \r\nBcc : samarlover.php@gmail.com \r\n
留言
\n --PHP-mixed-MIME_BOUNDARY_MESSAGE_PARTS \r\n Content-Type:text/html;\r\n Content-Transfer-Encoding: 7bit \n\n I Love Egypt\r\n\r\n --PHP-mixed-MIME_BOUNDARY_MESSAGE_PARTS \r\n Content-Type: application/octet-stream; name="file.txt" ; \r\n Content-Description: file.txt; \r\n Content-Disposition: attachment;filename=file.txt; size=38; \r\n Content-Transfer-Encoding: base64 \n\ndGhpcyBpcyBhdHRhY2hlZCBmaWxlIGluIG1haWwgZnVuY3Rpb24=
什么是问题以及如何解决它
【问题讨论】:
-
在
Return-Path标头之前缺少\r\n,而\r\n\r\n在From:标头之前应该只有\r\n。还要确保您的服务器满足向大型 ISP 发送邮件的要求,例如正确的 DNS 记录和 IP 的非通用主机名。
标签: php email sendmail email-headers