服务器拒绝超出“500行限制”的邮件

我正在使用一个PHP邮件类从网上商店发送一些邮件(主要是订单确认)。 邮件通过本地Exchange / SMTP服务器发送。

在大多数情况下,这工作正常,客户收到带有PDF附件的HTML邮件。 但在某些情况下,客户抱怨没有收到任何邮件。

MS Exchange通知有关被多个服务器拒绝的邮件 – 所有的邮件都有相同的错误信息:

500线超出限制

问题来自我的邮件/邮件类,还是服务器设置? 我能做些什么来避免呢?

RFC 821规定了SMTP传输的最大行长度:

command line The maximum total length of a command line including the command word and the <CRLF> is 512 characters. reply line The maximum total length of a reply line including the reply code and the <CRLF> is 512 characters. text line The maximum total length of a text line including the <CRLF> is 1000 characters (but not counting the leading dot duplicated for transparency). 

我认为你的信息超出了上述限制之一 – 交易似乎没有打扰,但其他服务器将会。