我对 HTML 电子邮件开发还比较陌生,我正在尝试通过剖析“reallygoodemails.com”上的 HTML 电子邮件来提高对 HTML 电子邮件结构的理解。
在我的尝试中,我遇到了四种不同的方法来为非 Microsoft Outlook 的电子邮件平台创建条件后备。
版本 1。
<!--[if !mso]><!-->
<style>
.innerTable{
border: 1px solid black;
}
</style>
<![endif]-->Run Code Online (Sandbox Code Playgroud)
版本 2。
<!--[if !mso]><!---->
<style>
.innerTable{
border: 1px solid black;
}
</style>
<![endif]-->Run Code Online (Sandbox Code Playgroud)
版本 3。
<!--[if !mso]><!---->
<style>
.innerTable{
border: 1px solid black;
}
</style>
<!--<![endif]-->Run Code Online (Sandbox Code Playgroud)
版本 4。
<!--[if !mso]>-->
<style>
.innerTable{
border: 1px solid black;
}
</style>
<!--<![endif]-->Run Code Online (Sandbox Code Playgroud)
谁能告诉我应该使用哪个版本并解释为什么该特定版本实际上可以跨平台工作?例如,您选择的后备语法如何欺骗 MSO 忽略代码?
我对 HTML 电子邮件开发比较陌生,我正在尝试了解嵌套表,特别是何时嵌套表、创建 tr 标记对或添加 td 标记对。\n下面是代码来自位于此 URL 的 HTML 电子邮件的真实示例的片段,以说明我的困惑的基础:https://reallygoodemails.com/emails/save-30-for-our-winter-sale/live
\n<body style="margin:0; padding:0; min-width:100%; background-color:transparent;">\n <div style="display:none;font-size:1px;line-height:1px;max-height:0px;max-width:0px;opacity:0;overflow:hidden;mso-hide:all;">Our Winter Sale gets better</div>\n <div style="display:none;font-size:1px;line-height:1px;max-height:0px;max-width:0px;opacity:0;overflow:hidden;mso-hide:all;"> ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌\n ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌</div>\n <table width="100%" class="body" cellpadding="0" cellspacing="0" border="0" role="presentation">\n <tr>\n <td style="background-color:transparent;">\n <table width="100%" class="Wrapper" cellpadding="0" cellspacing="0" border="0" role="presentation">\n <tr>\n <td align="center" style="background-color:transparent; border-top-style: none; border-bottom-style: none; border-right-style: none; border-left-style: none; border-top-width: 0px; border-bottom-width: 0px; border-right-width: 0px; border-left-width: 0px; border-color: #222222;">\n\n <!--[if(gte mso 9)|(IE)]><table width="600" cellpadding="0" cellspacing="0" border="0" style="width: 600px;" role="presentation"> <tr> <td …Run Code Online (Sandbox Code Playgroud)