- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我正在构建一个流畅的混合电子邮件,出于某种原因,这个单列不断扩展到我的 600 像素 Outlook 2007+ 容器之外。当我在 Litmus 中测试它时,一切都很好,但是当我在 Outlook 2010 中实际查看它时,我遇到了一些问题。标题图片下方有 1px 的间距,单列(带有文本)扩展到 600px 以上。我尝试了通常的嫌疑人(显示:阻止 img,valign 底部)但没有运气。
请注意,我有一个针对 Outlook 2007+ 显示的条件标题图像。
有什么想法吗?提前致谢!
代码如下:
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!--[if !mso]><!-->
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<!--<![endif]-->
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title></title>
<!--[if (gte mso 9)|(IE)]>
<style type="text/css">
table {border-collapse: collapse;}
.legal {padding-left: 20px;}
.footer {display: none !important;}
</style>
<![endif]-->
<!--[if lte mso 11]>
<style type="text/css">
.header {display: none;}
</style>
<![endif]-->
<style type="text/css">
.sellPoints {
font-size: 10px;
padding-bottom: 5px;
padding-left: 42px;
}
.mainPoints {
font-size: 12px;
}
body {
margin: 0 !important;
padding: 0;
background-color: #ffffff;
}
table {
border-spacing: 0;
font-family: sans-serif;
color: #333333;
}
td {
padding: 0;
}
img {
border: 0;
}
div[style*="margin: 16px 0"] {
margin: 0 !important;
}
.wrapper {
width: 100%;
table-layout: fixed;
-webkit-text-size-adjust: 100%;
-ms-text-size-adjust: 100%;
}
.webkit {
max-width: 600px;
margin: 0 auto;
}
.outer {
Margin: 0 auto;
width: 100%;
max-width: 600px;
}
/*Full width image*/
.full-width-image img {
width: 100%;
max-width: 600px;
height: auto;
}
/*<!-- Single column row layout -->*/
.inner {
padding: 10px;
}
p {
Margin: 0;
}
a {
color: #ee6a56;
text-decoration: underline;
}
.h1 {
font-size: 21px;
font-weight: bold;
Margin-bottom: 18px;
}
.h2 {
font-size: 18px;
font-weight: bold;
Margin-bottom: 12px;
}
/* One column layout */
.one-column .contents {
text-align: left;
}
.one-column p {
font-size: 14px;
Margin-bottom: 10px;
}
/*Double column row layout*/
.two-column {
text-align: center;
font-size: 0;
}
.two-column .column {
width: 100%;
max-width: 300px;
display: inline-block;
vertical-align: top;
}
.contents {
width: 100%;
}
.two-column .contents {
font-size: 14px;
text-align: left;
}
.two-column img {
width: 100%;
max-width: 300px;
height: auto;
}
.two-column .text {
padding-top: 10px;
}
</style>
<body>
<center class="wrapper">
<div class="webkit">
<!--[if (gte mso 9)|(IE)]>
<table width="600" align="center">
<tr>
<td>
<![endif]-->
<table class="outer" align="center">
<tr>
<td>
<!-- Two column row layout -->
<!-- Full width banner image -->
<!--[if gte mso 9]>
<table class="outer" align="center">
<tr>
<td class="full-width-image" valign="bottom">
<img style="display: block; width: 600px !important;" src="http://www.thedognamer.com/wp-content/uploads/2015/07/seinfeld-dog-names.png" width="600" alt="" />
</td>
</tr>
</table>
<![endif]-->
<!-- End Full width banner image -->
<!--[if !mso]><!-- -->
<tr>
<td class="two-column header" bgcolor="#83bae6" style="background-color: #83bae6;">
<!--[if (gte mso 9)|(IE)]>
<table width="100%" cellspacing="0" cellpadding="0">
<tr>
<td width="50%" valign="top">
<![endif]-->
<div class="column">
<table width="100%" cellspacing="0" cellpadding="0">
<tr>
<td>
<table class="contents" cellspacing="0" cellpadding="0">
<tr>
<td align="center">
<img style="display: block;" src="https://s-media-cache-ak0.pinimg.com/736x/03/a8/68/03a868689a6c3eb81767e18ee246ebfe.jpg" alt="" />
</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
<!--[if (gte mso 9)|(IE)]>
</td><td width="50%" valign="top">
<![endif]-->
<div class="column">
<table width="100%" cellspacing="0" cellpadding="0">
<tr>
<td>
<table class="contents" cellspacing="0" cellpadding="0">
<tr>
<td align="center">
<img style="display: block;" src="https://s-media-cache-ak0.pinimg.com/736x/03/a8/68/03a868689a6c3eb81767e18ee246ebfe.jpg" alt="" />
</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
<!--[if (gte mso 9)|(IE)]>
</td>
</tr>
</table>
<![endif]-->
</td>
</tr>
<!--<![endif]-->
<!-- End Two column row layout -->
<!-- Single column row layout -->
<tr>
<td class="one-column">
<table width="100%" cellspacing="0" cellpadding="0">
<tr>
<td class="contents" bgcolor="#5477b9" style="background-color: #5477b9;text-align: center;color: #ffffff;padding-top: 8px; padding-bottom: 0; Margin-bottom: 8px;">
<p class="h1">Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient mo</p>
</td>
</tr>
</table>
</td>
</tr>
<!-- End Single column row layout -->
</td>
</tr>
</table>
<!--[if (gte mso 9)|(IE)]>
</td>
</tr>
</table>
<![endif]-->
</div>
</center>
最佳答案
有时使用 HTML 电子邮件您会忘记最简单的事情...
通过将 border="0"添加到包含图像的表中,问题就消失了。
关于html - Outlook 2007+ 单列行的额外间距,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40868965/
我有一个针对单行中的单个列的mysql查询 "SELECT some_col_name FROM table_name WHERE user=:user" 执行语句$stmt->execute();后
我想创建一个应用程序,以这种格式在核心文本(滑动到下一页)中显示捆绑文本文件: 旁遮普语文本 旁遮普语音译成英语 旁遮普语翻译成英语 但我希望用户能够通过设置选项卡选择显示的语言,我知道该怎么做,即
我已经在 Angular 应用程序中设置了一个 ag-grid。我正在尝试使单列填充网格的整个宽度。 但后来我明白了。
当我在 excel 中打开我的 csv 文件时,它看起来像这样 - header 值 1值2值3值4值5 我想知道这个文件中是否真的有逗号?我知道如果我有多个列,我会看到逗号 最佳答案 您可以通过在文
我目前正在运行如下查询: SELECT a.ID, a.ContactID, a.Code, FROM tableA a JOIN (SELECT ContactID, Code FROM
当我在 excel 中打开我的 csv 文件时,它看起来像这样 - header 值 1值2值3值4值5 我想知道这个文件中是否真的有逗号?我知道如果我有多个列,我会看到逗号 最佳答案 您可以通过在文
我正在使用 codeigniter insert_batch($table, $data);我的列名称为“客户发布的评论”。 当我尝试批量插入数据时。插入查询更改为: INSERT INTO `tab
我有两个问题: 我想知道这是否是对单列 TreeView 进行搜索/过滤的正确方法。我觉得我的很多复制/粘贴可能包含不必要的东西。 QSortFilterProxyModel子类中的所有代码和sear
我有一个应用程序,我想获取多个软件包的 RPM 信息,并以令人愉悦且引人注目的方式对其进行格式化。 *繁荣*。 我的问题是 rpm 想要将数据格式化为两列,这很烦人。 命令 rpm -qi ruby
具有单列表(身份列)的目的是什么?有没有好的用例可用? 这真的是一个好习惯吗? 最佳答案 我认为人们使用它来复制 Oracle 的 SEQUENCE。基本上,他们希望他们在系统中创建的任何实体都有一个
我正在将数据库连接从 mysqli 转移到 PDO。更新时,我陷入了一个查询:在mysql中它是: $quec='designation=10 OR designation=11 OR designa
给定MySQL中的一列字符串(密码)并给定一个值N,我正在寻找一种sql方式来计算每个n-的频率gram(长度为 n 的子串)。 将代码保留在 MySQL 中很重要,因为在我拥有的其他环境中,它会导致
我对 GtkTreeView 有以下问题。 当我尝试附加列表时出现问题。这是我创建的函数: static GtkWidget *setup_list_archive(GtkWidget **wid
我是 JPA/Hibernate 的新手。假设我有这两个表: Employee (Id, Name, DeptId, ..)//DeptId 是外键。 Department (Id, DeptName
我正在调用的 REST API 返回一个数组,格式如下: ["a", "b", "c", "d"] 我的 ui-grid 需要在单列中显示这些数据条目,每行一个。 我有: $scope.items
我正在使用由 passy 创建的 Angular masonry 指令,当第一个元素的宽度几乎达到 100% 时我遇到了问题。在这种情况下,所有元素都合并在一个列中,否则我认为行为没问题。 我创建了一
我想将此嵌套数组转换为单个 pandas 数据框列,我该怎么做?有人可以帮我吗? array([array([ nan, 16.40411828, 23.671878
有一个遗留的 LAMP 应用程序,我正在将其转换为 JVM。 所讨论的问题需要一个包含@250K 记录的评分表。目前,“scoreType”列表示为tinyint,其中1 = 目标,2 = 协助1,3
我正在考虑 MySQL 5.6 InnoDB 表的以下架构。我无法决定使用哪些键: "CREATE TABLE IF NOT EXISTS `context` (" " `text_
我是一名优秀的程序员,十分优秀!