- android - 多次调用 OnPrimaryClipChangedListener
- android - 无法更新 RecyclerView 中的 TextView 字段
- android.database.CursorIndexOutOfBoundsException : Index 0 requested, 光标大小为 0
- android - 使用 AppCompat 时,我们是否需要明确指定其 UI 组件(Spinner、EditText)颜色
我有一个包含 3 列的页脚,这些列都严格嵌套在 HTML 电子邮件模板的基于表格的布局中。我正在尝试修复页脚,其中第三列的行高与前两列的顶部基线不匹配。
我一直在研究以查看是否有解决此问题的方法,并尝试了 mso-line-height-rule:exactly; 的变体; mso-text-raise:44px;
到声明了 line-height
的最后一列,但它似乎没有任何效果。
您可以在下图中看到,文本在最后一列向下移动并且文本间隔有点不同于在电子邮件中正确呈现的第二个图像。
Outlook 2013(在 Amazon Workspace - Windows 7 Pro 中):
Mac 版 Outlook 2011:
页脚代码:
<!-- Footer -->
<table width="100%" border="0" cellspacing="0" cellpadding="0" bgcolor="#ffffff">
<tr>
<td class="content-spacing" style="font-size:0pt; line-height:0pt; text-align:left" width="1"></td>
<td align="center">
<table width="650" border="0" cellspacing="0" cellpadding="0" class="mobile-shell">
<tr>
<td class="td" style="width:650px; min-width:650px; font-size:0pt; line-height:0pt; padding:0; margin:0; font-weight:normal; Margin:0">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="spacer" style="font-size:0pt; line-height:0pt; text-align:center; width:100%; min-width:100%"><tr><td height="25" class="spacer" style="font-size:0pt; line-height:0pt; text-align:center; width:100%; min-width:100%"> </td></tr></table>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<!-- Column 1 -->
<th class="column-top" style="font-size:0pt; line-height:0pt; padding:0; margin:0; font-weight:normal; vertical-align:top; Margin:0" width="150">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><div class="img" style="font-size:0pt; line-height:0pt; text-align:left"><image src="https://www.designevo.com/res/templates/thumb_small/black-and-yellow-basketball.png" border="0" width="120" height="120" alt="Healthy Moms. Strong Babies." /></div></td>
</tr>
</table>
</th>
<!-- END Column 1 -->
<!-- Column -->
<th class="column" style="font-size:0pt; line-height:0pt; padding:0; margin:0; font-weight:normal; Margin:0" width="20"><div style="font-size:0pt; line-height:0pt;" class="mobile-br-20"></div></th>
<!-- END Column -->
<!-- Column 2 -->
<th class="column-top" style="font-size:0pt; line-height:0pt; padding:0; margin:0; font-weight:normal; vertical-align:top; Margin:0" width="150">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<!-- Button -->
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td align="left">
<table border="0" cellspacing="0" cellpadding="0" bgcolor="blue" style="border-radius: 0;">
<tr>
<td class="img" style="font-size:0pt; line-height:0pt; text-align:left" width="18"></td>
<td>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="spacer" style="font-size:0pt; line-height:0pt; text-align:center; width:100%; min-width:100%"><tr><td height="10" class="spacer" style="font-size:0pt; line-height:0pt; text-align:center; width:100%; min-width:100%"> </td></tr></table>
<div class="text-button" style="color:#ffffff; font-family:Arial,sans-serif; font-size:19px; line-height:18px; text-align:center; text-transform:uppercase">
<a href="#" target="_blank" class="link-white" style="color:#ffffff; text-decoration:none"><span class="link-white" style="color:#ffffff; text-decoration:none; font-weight:bolder;">BUTTON</span></a>
</div>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="spacer" style="font-size:0pt; line-height:0pt; text-align:center; width:100%; min-width:100%"><tr><td height="10" class="spacer" style="font-size:0pt; line-height:0pt; text-align:center; width:100%; min-width:100%"> </td></tr></table>
</td>
<td class="img" style="font-size:0pt; line-height:0pt; text-align:left" width="18"></td>
</tr>
</table>
</td>
</tr>
</table>
<!-- END Button -->
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="spacer" style="font-size:0pt; line-height:0pt; text-align:center; width:100%; min-width:100%"><tr><td height="10" class="spacer" style="font-size:0pt; line-height:0pt; text-align:center; width:100%; min-width:100%"> </td></tr></table>
<div class="text-col-2" style="color:#0F1934; font-family:Arial,sans-serif; font-size:14px; line-height:24px; text-transform:capitalize; font-weight: bolder; text-align:left;">
<span class="purple-text">Connect With Us</span>
</div>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="spacer" style="font-size:0pt; line-height:0pt; text-align:center; width:100%; min-width:100%"><tr><td height="5" class="spacer" style="font-size:0pt; line-height:0pt; text-align:center; width:100%; min-width:100%"> </td></tr></table>
<!-- Social Icons -->
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="img" style="font-size:0pt; line-height:0pt; text-align:left" width="27"><a href="#" target="_blank"><img alt="#" src="" width="23" height="23"/></a></td>
<td class="img" style="font-size:0pt; line-height:0pt; text-align:left" width="27"><a href="#" target="_blank"><img alt="#" src="#" width="23" height="23"/></a></td>
<td class="img" style="font-size:0pt; line-height:0pt; text-align:left" width="25"><a href="#" target="_blank"><img alt="#" src="#" width="21" height="23"></a></td>
<td class="img" style="font-size:0pt; line-height:0pt; text-align:left" width="27"><a href="#" target="_blank"><img alt="#" src="#" width="23" height="23"></a></td>
</tr>
</table>
<!-- END Social Icons -->
</td>
</tr>
</table>
</td>
</tr>
</table>
</th>
<!-- END Column 2 -->
<!-- Column -->
<th class="column" style="font-size:0pt; mso-line-height-rule:exactly; line-height:0pt; padding:0; margin:0; font-weight:normal; Margin:0" width="20"><div style="font-size:0pt; line-height:0pt;" class="mobile-br-20"></div></th>
<!-- END Column -->
<!-- Column 3 -->
<th class="column-top" style="font-size:0pt; mso-line-height-rule:exactly; line-height:0pt; padding:0; margin:0; font-weight:normal; vertical-align:top; Margin:0" width="400">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><div class="text-col-3 copyright-text" style="color:#0F1934; font-family:Arial,sans-serif; font-size:14px; mso-line-height-rule:exactly; mso-text-raise:44px; line-height:24px; text-align:left;">
<span style="font-size:14px; color:#787985; mso-line-height-rule:exactly; mso-text-raise:44px; line-height:15px;">The Company, 1234 Main Street
<br/>
Suite 9999, Los Angeles, CA 10001</span>
<br/>
<br/>
<span style="font-size:12px; color:#787985; mso-line-height-rule:exactly; mso-text-raise:44px; line-height:17px;">&copy; 2019 The Company
<br/>
All Rights Reserved
<br/>
<a href="#" target="_blank" style="color:#787985;">Terms, Privacy & Notices</a></span>
</div>
</td>
</tr>
</table>
</th>
<!-- END Column 3 -->
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="spacer" style="font-size:0pt; mso-line-height-rule:exactly; line-height:0pt; text-align:center; width:100%; min-width:100%"><tr><td height="50" class="spacer" style="font-size:0pt; line-height:0pt; text-align:center; width:100%; min-width:100%"> </td></tr></table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
<td class="content-spacing" style="font-size:0pt; line-height:0pt; text-align:left" width="1"></td>
</tr>
</table>
<!-- END Footer -->
最佳答案
Outlook 对 div
的支持参差不齐。
删除 div
并将样式表移动到父级 td
。请改用 line-height
,因此它适用于所有电子邮件客户端。
删除 span
并改用 p
。
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="text-col-3 copyright-text" style="color: #0F1934; font-family: Arial,sans-serif; font-size: 14px; line-height: 15px; text-align: left;">
<p>The Company, 1234 Main Street
<br />
Suite 9999, Los Angeles, CA 10001</p>
<p>&copy; 2019 The Company
<br />
All Rights Reserved
<br />
<a href="#" target="_blank" style="color: #787985;">Terms, Privacy & Notices</a></p>
</td>
</tr>
</table>
祝你好运。
关于css - mso-line-height 和 mso-text-raise 在 Outlook 2013 中不起作用?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/55563283/
CREATE OR REPLACE FUNCTION mover(src text, dst text, cpquery text, conname text, ifbin boolean) retu
在python中,raise和raise e在except block 中有区别吗? dis 向我显示不同的结果,但我不知道这是什么意思。 两者的最终行为是什么? import dis def a()
当使用 pytest.raises 测试由 try/except block 捕获的错误时,由于未引发错误而失败。 如果我使用字典查找进行简单测试,并且不对其进行 try/except 操作,则 py
我有以下代码 if self.download_format == 'mp3': raise NotImplementedError elif self.downloa
在技术、哲学、概念或其他方面有什么区别 raise "foo" 和 raise Exception.new("foo") ? 最佳答案 从技术上讲,第一个引发 RuntimeError,消息设置为 "
定义无参数异常: class MyException(Exception): pass 当提出时,有什么区别: raise MyException 和 raise MyException()
标题很容易理解——它们之间的区别是什么 raise Exception, "foo" 和 raise Exception("foo") 它做的事情是否完全相同,只是语法不同? 我使用的是 Python
为了处理 Rails 异常,我看到人们使用“raise SomeException.new”或“raise SomeException”,有什么区别? 说如果我有课 class UnableToCr
当我从终端运行我的 .py 文件时,我没有收到任何错误,但是当我作为可执行文件(完全相同的应用程序)运行时,我在这一行收到错误 raise RuntimeError(f'Line lengths in
我在编写一小段代码时遇到了困难: act_therm.sa_handler=handler_therm; sigaction(SIGUSR1,&act_thermom,NULL); w
我试图在此页面中显示四张照片: http://progenygenealogy.com/products/family-tree-charts/photo-gallery-2.aspx 我怎样才能让左
什么是raise A, B做?它与raise A有何不同?是吗? 一些例子(运行在python 2.7的解释器上): class E(Exception): pass e = E() rais
如何优雅地实现 "Samurai principle" (返回胜利,或者根本没有)我的功能? return if else raise 最佳答案 如果你绝对想在表达式中 raise,你可以这样做
Python中的raise和raise from有什么区别? try: raise ValueError except Exception as e: raise IndexError
Python中try块可以捕获测试代码块中的错误。except块可以处理错误。finally块可以执行代码,而不管try-和except块的结果如何。本文主要介绍Python 抛出引发异常(rais
我正在用 d3js 构建一个网络(基本上是节点和链接) 当我将鼠标悬停在一个节点上时,我想突出显示关联的链接并将它们置于父节点的顶部以使其真正可见 在鼠标悬停时,我做了这样的东西 // get lin
在 WPF 中,我正在尝试使用 moq 来引发一个事件,该事件具有与其 Hook 的异步监听器: 我的代码: public class Provider { private I
我在这段代码(来自 https://www.django-rest-framework.org/tutorial/3-class-based-views/ )上有一条 pylint 消息(w0707)
我有一个带有 Let 函数的类模块,该函数会引发自定义错误,示例如下所示 Private pValue As Double Public Property Let Value(v As Double)
我试图将表限制为只有一条记录,并禁止所有添加更多记录的尝试。我创建了此触发器:CREATE TRIGGER abort_insert_to_my_tbl BEFORE INSERT ON my_tbl
我是一名优秀的程序员,十分优秀!