此消息已被修改以适合您的屏幕.点按这里显示原始

yev*_*niy 2 html email gmail html-email

我制作了固定电子邮件模板 但是当我尝试在gmail中的移动设备上测试它时(它只在gmail中发生)它会破坏我的布局(看起来它使我的布局适合设备宽度,就像在响应式电子邮件中一样).有一条消息:"此消息已被修改以适合您的屏幕.点击此处显示原始信息".点击后它看起来很完美,没有任何缺陷.有没有任何方法可以防止这种情况,并在开始时显示原始电子邮件?

yev*_*niy 6

找到了答案.也许它有助于某人.要显示原始布局需要添加到电子邮件末尾的此代码.

<tr>
<div style="display:none; white-space:nowrap; font:15px courier; line-height:0;">
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
</div>
</tr>
Run Code Online (Sandbox Code Playgroud)

白色空间:带有虚线的nowrap创建一条大约500px的线,当大小增加时将超过700px,导致Gmail不应用字体更改.

显示:无样式导致非Gmail客户端隐藏阻止(Gmail忽略显示:无).例如,在非Gmail移动客户端中查看电子邮件时,它不会影响响应式布局.