开发者

Using html page as mail body in asp.net

开发者 https://www.devze.com 2023-01-19 08:42 出处:网络
I have an emai开发者_C百科l template in a file called template.html, how can i use it as mail body in asp.net?There\'s a sample here with code.

I have an emai开发者_C百科l template in a file called template.html, how can i use it as mail body in asp.net?


There's a sample here with code.

Or you could use the MailDefinition class.


You can use this:

File.ReadAllText("template.html")

//This is to read template.html then you can pass this through
//formatemail() function if you have or
//message.body = File.ReadAllText("template.html");
0

精彩评论

暂无评论...
验证码 换一张
取 消