HTML电子邮件:背景图像在邮件中显示不正确



我正在创建HTML电子邮件。

当我通过单击邮件在浏览器中看到时,背景显示不正确。

<table>
<tr>
        <td align="middle" style="background-image: url(http://i.imgur.com/ixr4wNC.jpg); background-size: cover; height: 740px; ">
            <table cellspacing="0" cellpadding="0" border="0" style=" margin: 0 auto !important; padding: 0px; width:600px !important; line-height: 100% !important; border-collapse: collapse;mso-table-lspace: 0pt;mso-table-rspace: 0pt;" >
                <tbody>
                <tr>
                    <td valign="top" align="center">
                        <table cellspacing="0" cellpadding="0" border="0" style="width: 100%; border-collapse: collapse;mso-table-lspace: 0pt;mso-table-rspace: 0pt; font-family: SansSerif; ">
                            <tbody>
                            <tr>
                                <td style="height: 450px; visibility: hidden;">text</td>
                            </tr>
                                <tr>
                                    <td style="padding-top: 10px; font-size: 12px; padding-left: 20px;">
                                        
                                    </td>
                                </tr>
                            </tbody>
                        </table>
                    </td>
                </tr>
                </tbody>
            </table>
        </td>
    </tr>
</table>

显然谷歌的解析器不喜欢独立的background-size声明,所以它必须作为速记包含在内,否则它将被剥离。

background: url('image.gif') no-repeat center center / 100%;

最新更新