Randy is trying to say that this is very unreliable, as the user may
not have an email client configured, or it may not support all the
features of mailto.
For example, Lotus Notes will not accept a body of more than 200
characters, so whilst you may get away with this on a controlled
intranet, you should not use it on the web.
The following works with Lotus Notes based on the principle of escaping
the text (%0A is a return):
<a href='mailto:
[email protected]?SUBJECT=E-mail with broken
lines&body=Here%20is%20a%20line%20with%0Aa%20break'>Click
here to send...</a>
An alternative using \n and the escape function (you can use \r too if
that suits better):
<a href='' onclick="
this.href='mailto:
[email protected]?SUBJECT=E-mailform&body='
+ escape('This is\na broken\nline');
">Click here to send...</a>
As noted, only lightly tested and certainly not considered suitable for
the web for the stated reasons.
Cheers, Rob.