Reputation: 6543
We currently have a bad situation where I need to change HTML Body content from a CMS and convert it to plain text so it can go into the body of an emailto.
private static string StripHtmlToAscii(string mergeEmailBody)
{
var asciiEmailBody = mergeEmailBody;
asciiEmailBody = asciiEmailBody.Replace("<br />", "%0D%0A").Replace("<br/>", "%0D%0A").Replace("+", "%20").Replace(" ", "%20").Replace("<p>", "").Replace("</p>", "%0D%0A%0D%0A").Replace("<br>", "%0D%0A");
return asciiEmailBody;
}
See above..
I am wondering is it possible to add style like bold or colour to a plain text email ?
Upvotes: 0
Views: 304
Reputation: 1756
No, plain text is plain text, it will only accept text. The only way you can add colour is by sending an HTML email
Upvotes: 1