A
A
Alexey Smirnov2017-11-09 14:44:30
css
Alexey Smirnov, 2017-11-09 14:44:30

How to send HTML/CSS letter to email?

Hello.
I'm trying to send an HTML email to Gmail (via the MailKit C# library). Everything goes and everything arrives well. But the text comes in the form of HTML markup. That is, the markup when receiving a letter is not processed.
I send the following HTML code (under the spoiler):

Spoiler
<html>
  <head>
    <style>
      .colored {
        color: blue;
      }
      #body {
        font-size: 14px;
      }
    </style>
  </head>
  <body>
    <div id='body'>
      <p>Hi Pierce,</p>
      <p class='colored'>This text is blue.</p=>
      <p>Jerry</p>
    </div>
  </body>
</html>


The HTML text is taken from here: developers.google.com/gmail/design/css
I try to simply paste the HTML code in the Gmail mail interface and send, I get the same thing - raw HTML code.
What should I do so that when I receive a letter, I see not HTML markup, but "beautiful formatted text"?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
T
tyzberd, 2017-11-09
@ERAFY

https://stackoverflow.com/questions/41160536/how-t...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question