苹果邮件大约每 72 个字符添加 \n - 我如何删除这些并保留实际的 \n

发布于 2024-08-04 07:15:31 字数 134 浏览 7 评论 0原文

查看从 AppleMail 生成的原始电子邮件,我似乎无法区分应用程序生成的 \n 字符和用户创建的 \n 字符之间的区别。程序生成的次数并不一致,但似乎在 70-73 范围内。我想将它们删除并由用户保存。

你们中有人遇到过类似的问题吗?

Looking at the raw, generated email generated from AppleMail, it doesn't appear that I can tell the difference between the \n characters generated by the application, and \n characters created by the user. The ones generated by the program do not have a consistent occurrence but it seems that it's in the range of 70-73. I would like to strip these out and save the ones by the user.

Have any of you had a similar problem?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

木落 2024-08-11 07:15:31

在我看来,软中断前面都有空格字符,而硬中断则不然。

当我尝试撰写一封在硬中断之前有空格的邮件时,邮件会在发送时删除该空格。

It looks to me like the soft breaks are all preceded by a space character, while the hard breaks are all not.

When I try to compose a message that has a space right before a hard break, Mail strips the space on send.

謌踐踏愛綪 2024-08-11 07:15:31

您可能想阅读您似乎在这里观察到的“流动”内容格式。您需要了解 MIME 才能正确处理这种情况。以下是摘录:

--Apple-Mail-103--514089007
Content-Type: text/plain;
    charset=US-ASCII;
    format=flowed;
    delsp=yes

请参阅 RFC 2646

You may want to read up on the "flowed" content format, which you seem to be observing here. You need to be MIME-aware to handle this situation properly. Here's an excerpt:

--Apple-Mail-103--514089007
Content-Type: text/plain;
    charset=US-ASCII;
    format=flowed;
    delsp=yes

Please see RFC 2646.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文