title: How do I send an HTML email?
body: <p>I have successfully sent email in my web application using JMS, but the result only displays in plain text. I want the content to be able to display html. How do I do it? Here is roughly what I have:</p>
  <pre><code>Message msg = new MimeMessage(mailSession);
  try{
      msg.setSubject(&quot;Test Notification&quot;);
      msg.setRecipient(Message.RecipientType.TO, new InternetAddress(sentTo, false));
      String message = &quot;&lt;div style=\&quot;color:red;\&quot;&gt;BRIDGEYE&lt;/div&gt;&quot;;
      msg.setText(message);
      msg.setSentDate(new Date());
      Transport.send(msg);
  }catch(MessagingException me){
      logger.log(Level.SEVERE, &quot;sendEmailNotification: {0}&quot;, me.getMessage());
  }
  </code></pre>