workaround for the 990 character limitation for email mailservers

大城市里の小女人 提交于 2019-11-28 12:23:51

You can put your content through the wordwrap() function so that you don't manually have to insert newlines.

Have you considered using one of the many mail libraries available? PHPMailer, PEAR Mail, SwiftMailer, etc...?

Order servers have an even lower limit: 76 chars per line + \r\n.

You have to make use of the imap_8bit() and imap_binary() functions in order to convert your data to a base64 or quoted-printable encoding.

You can also use an existing library, like SwiftMailer.

Actually, this is not a "mail server" problem. The SMTP line limit dictates the number of characters allowed on each line during transmission. The SMTP RFC allows for up to 1000 characters per line, and default postfix installed cap at 998 characters. You should contact your hosting provider on increasing your SMTP line limit if you feel it's necessary to exceed the RFC.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!