简体   繁体   English

使用VML时Outlook中的表格单元格对齐问题

[英]Table Cell Alignment Issue in Outlook when using VML

Seems like I'm having an alignment issue in Outlook 2010 and 2013 when I use vml for a table cell. 当我将vml用于表格单元格时,在Outlook 2010和2013中似乎遇到对齐问题。 The multi-colored background image appears fine in the right side table cell. 彩色背景图像在右侧表格单元格中显示良好。 The problem is with the table button(LEARN MORE) in the right side table cell. 问题出在右侧表格单元格中的表格按钮(了解更多)。 Instead of being aligned in the middle of the cell, it aligns to the top of the cell. 它不是对齐到单元格的中间,而是对齐到单元格的顶部。 This only occurs in Outlook 2010 and 2013. I included a jpg and code snippet below. 这仅在Outlook 2010和2013中发生。我在下面添加了jpg和代码段。 Anybody else come across this? 还有其他人遇到吗?

When I remove the vml code, the button aligns in the middle, Seems like it has something to do with the vml code. 当我删除vml代码时,按钮在中间对齐,似乎与vml代码有关。

Thank you for your time and guidance. 感谢您的时间和指导。

George 乔治

URL to image: http://epidm.edgesuite.net/CMS/BB/Untitled-1.jpg 图片网址: http : //epidm.edgesuite.net/CMS/BB/Untitled-1.jpg

<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="420" align="center" valign="middle"><a href="#" target="_blank"><img src="url" width="420" height="71" alt="Left Image" title="Left Image" border="0" style="display:block;"/></a></td>
<td width="180" height="71" align="center" valign="middle" background="http://epidm.edgesuite.net/CMS/BB/bb_w41_dinner_v1_06b.jpg">
    <!--[if gte mso 9]>
    <v:rect xmlns:v="urn:schemas-microsoft-com:vml" fill="true" stroke="false" style="width:180px;height:71px;">
    <v:fill type="tile" src="http://epidm.edgesuite.net/CMS/BB/bb_w41_dinner_v1_06b.jpg" color="#9db9922" />
    <v:textbox inset="0,0,0,0">
    <![endif]-->
            <table width="122" height="40" align="center" border="0" cellspacing="0" cellpadding="0">
            <tr>
            <td align="center" valign="middle" style="padding:10px 10px 10px 10px; font-family:Arial, Helvetica, sans-serif; font-size:14px; color:#ffffff; background-color:#eb298c;"><a href="#" target="_blank" style="color:#fffffe; text-decoration:none; font-weight:bold;">LEARN MORE</a></td>
            </tr>
            </table>
    <!--[if gte mso 9]>
    </v:textbox>
    </v:rect>
    <![endif]-->
</td>
</tr>
</table>

George, 乔治,

In case if you didn't know, Outlook uses Word as an email editor. 如果您不知道,Outlook将使用Word作为电子邮件编辑器。 You can read about supported and unsupported HTML elements, attributes, and cascading style sheets properties in the following articles in MSDN: 您可以在MSDN的以下文章中阅读有关受支持和不受支持的HTML元素,属性以及级联样式表属性的信息:

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM