如何在 Hotmail 中的 html 电子邮件中向 TABLE 或 DIV 添加边框?

发布于 2024-09-30 12:38:46 字数 280 浏览 11 评论 0原文

是的,html 电子邮件很糟糕,但我必须向我的客户列表发送 html 新闻通讯。他们中的大多数使用 Hotmail

是否可以在 /

元素周围添加 CSS 边框?

BORDER
不起作用

Yes, html emails are bad but I have to send html newsletter to my a list of clients. Most of them use Hotmail.

Is it possible to add a CSS border around a <table> / <div> element?

<div style="border:1px solid #000000;">BORDER</div> doesn't work

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

漆黑的白昼 2024-10-07 12:38:46

看起来最好的选择是在表中创建表:

<table bgcolor="#ACD13C" width="100%" cellpadding="2" cellspacing="0"><tr>
                                            <td><table bgcolor="#ffffff" width="100%" cellpadding="0" cellspacing="0">
                                               <tr>
                                                 <td style="font-weight: normal; font-size: 0.9em; color: #000000; font-family: Arial,helvetica,sans; padding:0px; text-align:left;" width="400">Text goes here</td>
                                                </tr>
                                            </table></td></tr></table>

Hotmail 只是不喜欢边框......

Looks like the best option is creating a table within a table:

<table bgcolor="#ACD13C" width="100%" cellpadding="2" cellspacing="0"><tr>
                                            <td><table bgcolor="#ffffff" width="100%" cellpadding="0" cellspacing="0">
                                               <tr>
                                                 <td style="font-weight: normal; font-size: 0.9em; color: #000000; font-family: Arial,helvetica,sans; padding:0px; text-align:left;" width="400">Text goes here</td>
                                                </tr>
                                            </table></td></tr></table>

Hotmail just doesn't like borders...

云胡 2024-10-07 12:38:46

尝试使用

border="1"

try to use

border="1"
べ映画 2024-10-07 12:38:46

尝试使用

<div style="border:1px solid black;">Hola</div>

是否有效

try to use

<div style="border:1px solid black;">Hola</div>

if it works

尘曦 2024-10-07 12:38:46

避免指定“black”等通用名称或十六进制颜色的缩短版本(如“#000”,这并不总是有效)的一种方法是单独指定每个元素,如下所示:

<table style="border-style:solid; border-width:1px; border-color:#000000;"><tr><td>....</td></tr></table>

One way to avoid specifying for a generic name like "black" or a shortened version of the hex color (like "#000", which does not always work) is to specify each element seperately like so:

<table style="border-style:solid; border-width:1px; border-color:#000000;"><tr><td>....</td></tr></table>
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文