You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@turbine.apache.org by Matthew Stone <st...@chesapeake.net> on 2002/04/03 21:02:31 UTC

HtmlEmail Problem

Hello,

I've been trying to get the HtmlEmail class to work.  I have successfully
gotten it to send e-mail but the test e-mail that I receive does not include
the message text I defined with setTextMsg() and setHtmlMessage().
Everything else is there i.e.: to, cc, bcc, subject.

Here's how I've tried to use it:

HtmlEmail email = new HtmlEmail();
email.setFrom("foo@chew.org", "Foo Man Chew");
email.addTo("me@somewhere.com","Me");
email.setSubject("Automated Message(plain text)");
email.setSentDate(new Date());
email.setTextMsg("This is plain text");
email.send();

email = new HtmlEmail();
email.setFrom("foo@chew.org", "Foo Man Chew");
email.addTo("me@somewhere.com","Me");
email.setSubject("Automated Message(very plain text)");
email.setSentDate(new Date());
email.setMsg("This is very plain text");
email.send();

email = new HtmlEmail();
email.setFrom("foo@chew.org", "Foo Man Chew");
email.addTo("me@somewhere.com","Me");
email.setSubject("Automated Message(html text)");
email.setSentDate(new Date());
email.setHtmlMsg("<html><body>This is <b>bold</b> text</body></html>");
email.send();

email = new HtmlEmail();
email.setFrom("foo@chew.org", "Foo Man Chew");
email.addTo("me@somewhere.com","Me");
email.setSubject("Automated Message(html text 2)");
email.setSentDate(new Date());
email.setHtmlMsg("This is <b>bold</b> text");
email.send();

As I said,  I'll receive every one of these e-mail's.  They just don't
contain any content in the message body.

Regards,
Matt


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>