雅虎忽略了为电子邮件设置了100%宽度和背景颜色的包装表。背景颜色显示为白色,内容左对齐,仅显示设置为600px的内部表格。以前测试过的电子邮件也存在同样的问题。任何有助于解决此问题的帮助都将受到高度赞赏。以下是Im测试的示例代码。
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0">
<title></title>
<style type="text/css">
.ReadMsgBody {width: 100%;}
.ExternalClass {width: 100%;}
</style>
</head>
<body style="background-color:#000000; margin:0px; padding:0px;" bgcolor="#000000">
<table border="0" width="100%" cellspacing="0" cellpadding="0" bgcolor="#000000">
<tr>
<td align="center" bgcolor="#000000" style="padding:20px;">
<table border="0" cellpadding="0" cellspacing="0" width="600" bgcolor="#1a1a1a">
<tr>
<td style="color:#FFFFFF;font-family:sans-serif;font-size:16px;line-height:22px; padding:20px; border:1px solid #cccccc;" align="left">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</td>
</tr>
</table></td>
</tr>
</table>
</body>
</html>
答案 0 :(得分:0)
在width ='600'之前添加宽度:1440px 像这样:
<td align="center" bgcolor="#000000" style="padding:20px; width: 1440px">
这将显示中间而非左侧的邮件内容
答案 1 :(得分:-1)
你尝试过不同的标题吗?这是我一直使用的那个。
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
另外(AFAIK)你将无法摆脱白色边框,这意味着你不能将身体拉伸到100%,总会有几个白色像素间隙。