Html电子邮件< hr />造型问题 [英] Html emails <hr/> styling issue

查看:142
本文介绍了Html电子邮件< hr />造型问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个电子邮件客户端的问题,将我的样式< hr /> 恢复为一个只是一个实线。

I have a problem with e-mail clients reverting my styled <hr/> to one with just a solid line.

以下是我的标记,在Chrome和IE中看起来很好,但是Outlook总是将虚线恢复为固定的。

The following is my mark-up, looks fine in Chrome and IE but Outlook always reverts the dotted line to a solid one.

<hr style="background:none; border:dotted 1px #999999; border-width:1px 0 0 0; height:0; width:100%; margin:0px 0px 0px 0px; padding-top:10px;padding-bottom:10px;" ></hr>

我看过Campaign Monitor,但没有什么可指导的。

I have looked at Campaign Monitor but nothing particular to guide me there.

所有答案都赞赏。

推荐答案

我想象是因为outlook使用微软字渲染引擎,而不是一个HTML引擎,而一个hr标签就可以像msword一样恢复为实线。

I would imagine it's because outlook uses the Microsoft word rendering engine, rather than a HTML engine, and a hr tag would just get reverted to a solid line as in msword.

我可能会尝试使用全宽表格 - >单元格或div和style,而不是使用hr标签。

I'd probably try using a full width table->cell or div and style that instead of using an hr tag.

<table>
<tr>
<td style="background:none; border:dotted 1px #999999; border-width:1px 0 0 0; height:1px; width:100%; margin:0px 0px 0px 0px; padding-top:10px;padding-bottom:10px;">&nbsp;</td>
</tr>
</table>

在这里,如果呈现引擎不识别为空单元格。

nbsp is in there in case the rendering engine doesn't recognise empty cells.

这篇关于Html电子邮件&lt; hr /&gt;造型问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆