以文本格式发送多行邮件 [英] sending multiline mail in text format
问题描述
Bonjour,
我正在使用PHPMailer类发送邮件,它适用于HTML。
但是我无法正确发送文本格式的邮件...
我试过这个:
- $ message ="第一行* \ n *第二行" ;;
- $ message ="第一行* \\\ n \\ n *第二行" ;;
- $ message =" first line *" .chr(13).chr(10)* second line" ;;
- $ message =" first line *
* second line" ;;
结果总是一样的(我尝试了许多邮件阅读器,如Outlook Express,
Yahoo,...):正文只出现在一行,间隔2
*,而不是回车...
第一行* *第二行
感谢您的任何想法!
Bonjour,
I''m using PHPMailer class to send mails and it works fine for HTML ones.
But I can''t manage to send correctly a text formatted mail...
I tried this :
- $message = "first line*\n*second line";
- $message = "first line*\r\n*second line";
- $message = "first line*".chr(13).chr(10)*second line";
- $message = "first line*
*second line";
Result is always the same (I tried many mail readers like Outlook express,
Yahoo, ...) : the body appears on only one line, with a space between the 2
*, instead of a carriage return...
first line* *second line
Thanks for any idea !
推荐答案
message ="第一行* \ n *第二行" ;;
-
message = "first line*\n*second line";
-
message =&q uot;第一行* \\\ n \\ n *第二行" ;;
-
message = "first line*\r\n*second line";
-
message =" first line *" .chr(13) .chr(10)*第二行;
-
message = "first line*".chr(13).chr(10)*second line";
-
这篇关于以文本格式发送多行邮件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!