Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8302051
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T17:11:24+00:00 2026-06-08T17:11:24+00:00

I want to send html email.I am using spring framework Mailsender class to send

  • 0

I want to send html email.I am using spring framework Mailsender class to send email and there is a email_en.xml file which contains the content which is something like

 <?xml version="1.0" encoding="UTF-8"?>
   <!DOCTYPE properties [ 
<!ELEMENT properties ( comment?, entry* ) >
<!ATTLIST properties version CDATA #FIXED "1.0">
<!ELEMENT comment (#PCDATA) >
<!ELEMENT entry (#PCDATA) >
<!ATTLIST entry key CDATA #REQUIRED>
  ]>
  <properties>
 <entry key="subject">
 email
</entry>
 <entry key="to">
   test@test.com
  </entry>
  <entry key="name">
       Garry
    </entry>
    <entry key="body">
   Dear User,
  <![CDATA[
    Dear User,
    <b>This is your email for reference</b>
    ]]>
    </entry>
    </properties>

So can I add html tags to this file I tried but it does not work. I have also added [CDATA[ ]] tag but it still not working.

Anyone can give me some idea

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T17:11:25+00:00Added an answer on June 8, 2026 at 5:11 pm

    Most likely you are using just MailSender and sending simple e-mail messages. In order to handle HTML content you should use JavaMailSender which offers you possibility to send MimeMessage.

    This Spring e-mail tutorial describes the differences, and how to correctly prepare e-mail messages (it’s for version 2.x.x, but should be applicable to 3.x.x).

    If you are using MimeMessageHelper, don’t forget to set the HTML flag to true when calling #setText method.

    P.S. It seems that you are using your custom utility to parse XML messages and turn them into Message beans. Review your code and make sure that appropriate setters are called since properties in your XML message doesn’t match property names in MailMessage.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

How can I send an HTML-formatted email with pictures using PHP? I want to
I want to send the HTML email to new registered user. I am using
I have a complex HTML form which I want to send via email. Is
I want to send a HTML email using ZEND_MAIL. The problem is that I
I want to render an HTML-EMail and send it to our customers using some
I want to send the email for html page. Is there any method to
I am sending email through gmail, i want to send some html content, is
I want send a email by Email Class in codeigniter with gmail, but i
I'm using System.Net.Mail to send an email message and want to make sure it
Hi there I'm trying to send an HTML email through a PHP webform. The

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.