Monday, November 08, 2010 at 12:05 AM.

system.verbs.builtins.radio.macros.mailTo

on mailTo () {
	<<Changes
		<<3/19/02; 5:50:21 PM by JES
			<<Return the empty string if you don't have a usernum. Prevents a macro error on the setup page.
		<<2/25/02; 8:09:29 PM by JES
			<<Get the mail page url from radio.data.cloudUrls.spamFreeMailto.
		<<1/31/02; 4:19:35 PM by DW
			<<Add an ALT attribute to the image.
		<<1/19/02; 2:16:19 PM by DW
			<<Created. Call this from a template to add a mailTo icon that readers can click on to send you an email, without disclosing your email address.
			<<http://radio.userland.com/spamFreeMailTo
	local (url = radio.data.cloudUrls.spamFreeMailto + "?usernum=" + string.padwithzeros (user.radio.prefs.usernum, 7));
	local (tooltip = "Click here to send an email to the editor of this weblog.");
	return ("<a href=\"" + url + "\" title=\"" + tooltip + "\"><img src=\"http://static.userland.com/shortcuts/images/qbullets/mailto.gif\" width=\"14\" height=\"10\" border=\"0\" alt=\"" + tooltip + "\"></a>")}
<<bundle //test code
	<<webbrowser.displaytext (mailto ())



This listing is for code that runs in the OPML Editor environment. I created these listings because I wanted the search engines to index it, so that when I want to look up something in my codebase I don't have to use the much slower search functionality in my object database. Dave Winer.