Steve Hooker's Radio Weblog :

 

 
 

Formatting email to blog

on SMSpicture (adrMsg) {
	local (msgText = adrMsg^.text);
	if (string.lower (adrMsg^.from)) contains (string.lower ("steve@myServer.com")) {
		adrMsg^.text = "<table border=\"0\" width=\"100%\" cellspacing=\"10\" cellpadding=\"0\"><tr><td align=\"left\" valign=\"top\"><a href=\"http://radio.weblogs.com/0001263/2002/01/10.html\"><img src=\"http://radio.weblogs.com/0001263/images/mystuff/phones/powerbook2.jpg\" border=\"0\" width=\"65\" height=\"60\" align=\"right\" hspace=\"10\" vspace=\"10\"></a></td><td align=\"left\" valign=\"top\">" + msgText + "</td></tr></table>";
		msg (adrMsg^.text)};
	if (string.lower (adrMsg^.from)) contains (string.lower ("myPhone@one2one.net")) {
		adrMsg^.text = "<table border=\"0\" width=\"100%\" cellspacing=\"10\" cellpadding=\"0\"><tr><td align=\"left\" valign=\"top\"><a href=\"http://radio.weblogs.com/0001263/2002/01/10.html\"><img src=\"http://radio.weblogs.com/0001263/images/mystuff/phones/6210a.jpg\" border=\"0\" width=\"70\" height=\"48\" align=\"right\" hspace=\"10\" vspace=\"10\"></a></td><td align=\"left\" valign=\"top\">" + msgText + "</td></tr></table>"}}

Just put the script above here: weblogData.callbacks.weblogCheckMail.SMSpicture. You'll need to change the email addresses, obviously, and the images, if you want, and the formatting, if you need to. Also, if you want access to the rest of the data that comes with the email message, here, the rest of it.

Content-transfer-encoding
Content-type
Date
From
fullHeader
Message-ID
Mime-version
msg
Received
Return-Path
Subject
text
To
User-Agent



© Copyright 2002 Steve Hooker.
Last update: 13/01/02; 1:39:33 am.