[OT] Extended mailto: links. The bad news?
[OT] Extended mailto: links. The bad news?
- Subject: [OT] Extended mailto: links. The bad news?
- From: Paul McCann <email@hidden>
- Date: Thu, 22 Mar 2001 21:23:36 +1030
Christopher Stone wrote...
>
Here's a useful resource for this sort of thing:
>
>
http://developer.netscape.com:80/viewsource/husted_mailto/mailto.html
(Re using mailto: links to fill the body of a message.) I've been here,
spent some time poking around, and have come to the conclusion that a
universal or near-universal solution is impossible. Here's why... To cut a
long story short (I lost my miiiind): someone I know wanted a link to fill
out a message to majordomo, pre-filled with the appropriate body to mimic an
unsubscribe message. For the "what's an editor?" type of user. That is, a
message whose body should read
unsubscribe
end
(the end prevents any signature lines that might follow being misinterpreted
as majordomo commands) We tried using the URL
mailto:email@hidden?Subject=whatever&Body=unsubscribe
end
as produced by the form on
http://developer.netscape.com:80/viewsource/husted_mailto/mailto.html
The problems:
Netscape 3, for example, doesn't seem to recognise the extended "
mailto:"
link that's being used (on any platform!). Assuming that you've entered your
details in the "Mail and News Preferences" panel it gets the address right
and formats a mail message, but doesn't fill in the body section. Just
another version 3 versus version 4 browser incompatibility.
In Communicator (which has a built in mail client) on Unix machines this
sort of link *nearly* works. The only problem being that the "end" appeared
on the same line as the subscribe message. Looks from the source like the
line ending is being specified via a "CR". Hence I suspect that the problem
could be the old mac vs pc vs unix line ending thing. I don't think that you
can specify more than one line of body text in a nice platform independent
way within a mailto URL. I tried substituting a linefeed character where the
CR now sits, in order for things to work on Unix, but that just stuffs up
the mac support! And you'll need *both* if PC's are to work. Sigh...
For what it's worth, the link given above worked fine on my *Mac*, with both
IE and Communicator. So at least circa 5% of customers will be happy!
(Corrections and clarifications welcomed, as always.)
If you want to get hoity-toity about it, here's the RFC low-down: it's much
as I surmised, and ruled by the usual line-ending incompatibilities. You're
officially _naughty_ if you just have a CR there as per the netscape dev
page!
>
5. Encoding
>
>
RFC 1738 requires that many characters in URLs be encoded. This affects the
>
mailto scheme for some common characters that might appear in addresses,
>
headers or message contents. One such character is space (" ", ASCII hex
>
20). Note the examples above that use " " for space in the message body.
>
Also note that line breaks in the body of a message MUST be encoded with
>
"
".
Following this gives a sad result: Outlook/Entourage on the mac--for
example-- doesn't like it. You get the typically ugly line feed character at
the start of the "end" line when using this specification in the above
example. Doubtless the PC folk would be a little happier however!
Cheers,
Paul
(enough enough enough... is it obvious I've got something due in about 10
hours from now? With 8 of those hours supposed to be spent sleeping?),