HTML电子邮件显示图像切片之间的差距

时间:2016-10-13 21:19:19

标签: html css email

我的HTML电子邮件在Gmail应用中查看时,图片之间只有一个像素差距。

如何摆脱这种差距,使我的图像切片看起来像一个流畅的图像?

我试过显示:阻止图像,填充:0和边距:0但我仍然有这个差距。

这是我的HTML:

<table border="0" cellpadding="0" cellspacing="0" style="width: 650px !important; padding: 0 !important;">
    <tr style="padding: 0 !important;">
        <td style="padding: 0 !important; line-height: 0;" align="left" valign="top">
            <a href="http://www.google.com/" target="_parent" style="display: block !important;"><img style="display: block !important; padding: 0 !important; margin: 0 !important;" border="0" src="01.jpg"></a>
        </td>
    </tr>
    <tr>
        <td style="padding: 0 !important; line-height: 0;" align="left" valign="top">
            <a href="http://www.google.com/" target="_parent" style="display: block !important;"><img style="display: block !important; padding: 0 !important; margin: 0 !important;" border="0" src="02.jpg"></a>
        </td>
    </tr>
    <tr>
        <td style="padding: 0 !important; line-height: 0;" align="left" valign="top">
            <a href="http://www.google.com/" target="_parent" style="display: block !important;"><img style="display: block !important; padding: 0 !important; margin: 0 !important;" border="0" src="03.jpg"></a>
        </td>
    </tr>
</table>

1 个答案:

答案 0 :(得分:0)

你只需要调整A标签的边距..

<table border="0" cellpadding="0" cellspacing="0" style="width: 650px !important; padding: 0 !important;">
    <tr style="padding: 0 !important;">
        <td style="padding: 0 !important; line-height: 0;" align="left" valign="top">
            <a href="http://www.google.com/" target="_parent" style="display: block !important;"><img style="display: block !important; padding: 0 !important; margin: 0 !important;" border="0" src="https://d1ok0qgebci2d3.cloudfront.net/91/650x366/TheatricalsCos_EM_10112016_01.jpg"></a>
        </td>
    </tr>
    <tr>
        <td style="padding: 0 !important; line-height: 0;" align="left" valign="top">
            <a href="http://www.google.com/" target="_parent" style="display: block !important;margin-top:-4px"><img style="display: block !important; padding: 0 !important; margin: 0 !important;" border="0" src="https://d1ok0qgebci2d3.cloudfront.net/91/650x98/TheatricalsCos_EM_10112016_02.jpg"></a>
        </td>
    </tr>
    <tr>
        <td style="padding: 0 !important; line-height: 0;" align="left" valign="top">
            <a href="http://www.google.com/" target="_parent" style="display: block !important;margin-top:-4px"><img style="display: block !important; padding: 0 !important; margin: 0 !important;" border="0" src="https://d1ok0qgebci2d3.cloudfront.net/91/650x148/TheatricalsCos_EM_10112016_03.jpg"></a>
        </td>
    </tr>
</table>