【发布时间】:2014-06-06 22:24:47
【问题描述】:
你们好聪明的朋友们。
我正在尝试为电子邮件客户端设置后备系统。在阅读了HTML Emails: fallback for mso conditional? 和其他很棒的博客之后,我似乎仍然缺少一些东西。我能够让电子邮件在 Outlook 中正确显示,但在 Gmail 中,VML 仍然呈现,这给了我两个图像。
<table border="0" cellpadding="0" cellspacing="0" width="100%" >
<tr>
<td></td>
<td rowspan=2 class="desktop">
<!--[if mso]>
<v:rect style="width:600px;height:281px;" strokecolor="none">
<v:fill type="tile" color="#363636" src="http://www.frugi.org/emailpi/assets/header.jpg" /></v:fill>
</v:rect>
<v:shape id="someName" style="position:absolute;width:600px;height:281px;">
<p style="font-family:Georgia; font-size:13px;"><h2 style="color:Red;">Text Over Image Hack!!!</h2></p>
</v:shape>
<div style="width:0px; height:0px; overflow:hidden; display:none; visibility:hidden; mso-hide:all;">
<![endif]-->
<img src="_PT_icon_personalize_05.png" style="width:0; overflow:hidden; display:none; float:left" >
<!--[if mso]>
</div>
<![endif]-->
</td>
</tr>
<tr>
<!--[if mso]>
<div style="width:0px; height:0px; overflow:hidden; display:none; visibility:hidden; mso-hide:all;">
<![endif]-->
<td colspan=2 ><h2 style="color:Red;max-width:480px; width:0; overflow:hidden; display:none;">Text Over Image Hack!!!</h2></td>
<!--[if mso]>
</div>
<![endif]-->
</tr>
</table>
我在这里遗漏了什么吗?
展望
邮箱
【问题讨论】:
-
不确定这是不是问题,但您将 div 包裹在 td 周围
-
查看backgrounds.cm 了解适用于两个(所有主要)客户端的可靠 VML 示例。
标签: html css email outlook gmail