aspose file tools*
The moose likes Java in General and the fly likes Email formating... Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Email formating..." Watch "Email formating..." New topic
Author

Email formating...

pradeep gamage
Ranch Hand

Joined: Aug 03, 2009
Posts: 85

I am developing web application using java , spring and jsf 2.
So when user register with system, system automatically send a email.
This is email sending template

.


I want insert images and create look nice email template. Please give me idea to create email template.
Thanks in Advance...


Software Engineer(BSC):SCJP 1.5
(Knowledge is power when applied)
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19541
    
  16

Use the Apache Commons Email library, in particular the HtmlEmail class, to create an HTML email message. You can use any formatting you want inside the HTML content. Images can be added inline through the example on the class' Javadoc page.

I'd also use the setTextMsg method to set a plain text part for those clients that do not support HTML emails. This should be a simplified version of your HTML part without all the fancy formatting and images.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
pradeep gamage
Ranch Hand

Joined: Aug 03, 2009
Posts: 85

Thank You Its Work for me...
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Email formating...
 
Similar Threads
Issue in Sending Email from Spring Mail
Guestion is Validate the text?
Mail API Problem
Can we attach multiple email addresses through spring email
Java Mail Authentication