HTML email side by side images 1-2px too wide per image

168 views Asked by At

Having trouble with emails that have multiple images side by side but each row has a different amount of columns/images. I'm putting a table in each row so I don't have to use colspan as the images are all different widths. The more images in a row, the wider the row even though all rows have the same combined width of all their images.

See image example here:

https://i.stack.imgur.com/5bPH2.jpg

Example HTML (See JS fiddle as the code won't post correctly here for some reason):

<table id="Table_1_col" width="600" border="0" cellpadding="0" cellspacing="0" background="ffffff"
   style="background:#fff;display:block;table-layout:fixed;border-collapse:collapse!important;mso-table-lspace:0;mso-table-rspace:0;border-spacing:0;border:0;mso-cellspacing:0;mso-padding-alt:0;padding:0;margin:0;font-size:0;line-height:0;width:600px;min-width:600px;max-width:600px;"
   valign="top">
<tbody>
<tr style="display:block;white-space:nowrap;">
    <td style="font-size:0;line-height:0;margin:0;padding:0;background:url(images/_TRAVEL-15_05.jpg);background-image:url(images/_TRAVEL-15_05.jpg);background-size:100% 100%;"
        valign="top" align="left"><a href="https://www.afterpay.com/en-AU/categories/travel" align="left"
                                     style="font-size:0;line-height:0;display:block;margin:0;padding:0;" target="_blank"><img src="images/_TRAVEL-15_05.jpg"
                                                                                                                              width="600" height="241" alt=""
                                                                                                                              style="float:left;width:600px;display:block;margin:0;outline:0;text-decoration:none;-ms-interpolation-mode:bicubic;border:0;"
                                                                                                                              border="0" align="left"></a></td>
</tr>
</tbody>

https://jsfiddle.net/jup4xw3v/3/

The email has a set width of 600px and the additional side width is most notable on mobile devices where it breaks the flow of the email. The rows are weird widths due to the click areas from our designer.

No matter what I try I can't seem to get the rows displaying at the exact same width.

0

There are 0 answers