【发布时间】:2017-03-06 11:25:56
【问题描述】:
SendGrid 默认在 header 中设置什么 Content-Type?
我有一个问题,即通过 Sendgrid 发送的 html 电子邮件格式不正确。
在我看到的电子邮件标题中
MIME-Version: 1.0
Content-Type: text/plain
然后在任何电子邮件客户端中呈现以下内容,无论是独立的还是基于 Web 的。
This is a multi-part message in MIME format.
--------------e21a5bffb444e61b8e8a30240210d506
Content-Type: text/html; charset=UTF-8; format=flowed
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
等等等等
标题中的 Content-type 是否应该是 multipart/mixed 或类似以正确呈现 html 和显示图像?
这是如何改变的?
可以通过发送到 SendGrid 的服务器的实际 html 以某种方式更改它吗?
任何反馈表示赞赏!
【问题讨论】:
-
请发布您用于发送电子邮件的代码。
标签: html email content-type sendgrid