GMAIL:此邮件已修改为适合您的屏幕。点按这里显示原始

时间:2016-08-31 04:20:27

标签: html email gmail html-email

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

message has been modified to fit screen

同样的问题已经出现在link。但是最近两三天后面的gmail应用程序被更新,这个黑客停止了工作。有没有人有任何解决方案?

解决方案:

<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>

2 个答案:

答案 0 :(得分:0)

要显示原始布局需要添加到电子邮件末尾的此代码。

<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>

Originale Answer

答案 1 :(得分:0)

请在移动原生应用的媒体查询中添加@class,其中包含display:none属性。

 <div class="display-mobile" style="white-space:nowrap; font:15px courier; line-height:0;width:600px!important;">&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; &nbsp; &nbsp; &nbsp; &nbsp;</div>

在媒体查询中添加此属性:

.display-mobile{display: none !important;}