mailto链接多个身体线 [英] mailto link multiple body lines
问题描述
无法让多行在mailto链接中正常工作
在我的情况下,我使用Outlook默认邮件阅读器对其进行测试。
以下内容放入锚点href:
mailto:email @ address .com?& subject = test& body = type%20your& body = message%20here
想法
您可以使用网址编码将新行编码为%0A
。
mailto:email@address.com?subject = test& body = type%20your%0Amessage%20here
尽管上述方法在很多情况下都可以使用,但用户olibre 指出控制mailto URI方案的RFC指定应该使用%0D%0A
(回车+换行)而不是%0A
(换行)。另请参阅:换行符。
having trouble getting multiple lines to work correctly in a mailto link
In my case I'm testing it with an Outlook default mail reader.
The following is put in an anchor href:
mailto:email@address.com?&subject=test&body=type%20your&body=message%20here
only "message here" shows up in the email body. (whether I use chrome or IE)
thoughts?
You can use URL encoding to encode the newline as %0A
.
mailto:email@address.com?subject=test&body=type%20your%0Amessage%20here
While the above appears to work in many cases, user olibre points out that the RFC governing the mailto URI scheme specifies that %0D%0A
(carriage return + line feed) should be used instead of %0A
(line feed). See also: Newline Representations.
这篇关于mailto链接多个身体线的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!