mailto主题示例:
<a href="mailto:no-one@snai1mai1.com?subject=free chocolate">example</a>
mailto内容:
<a href="mailto:no-one@snai1mai1.com?subject=look at this website&body=Hi,I found this website and thought you might like it http://www.geocities.com/wowhtml/">tell a friend</a>
正如评论中提到的那样subject
,body
必须适当地对和进行转义。encodeURIComponent(subject)
在每种情况下使用,而不是为特定情况手工编码。
%0D%0A // one line break