BM
0
Outlook 2016 ignoring Background Colors in TD's
So here is my code:
<tr>
<td height="10" bgcolor="#422c13" style="background-color:#422c13;height:10px;font-size:1px;line-height:0; -webkit-text-size-adjust:none;"><font style="display:none;"> </font></td>
</tr>
This should display a row with a height of 10px with a brownish background color.
In Outlook 2016 you see this:
That white bar is my code that is having the background color ignored...
In every other email client around your see this:
No white bar.
Why is Outlook 2016 refusing to display the background color?
Any help greatly appreaciated!!!
Thanks,
Brian
I thought maybe the display:none on the font tag was causing the problem so I changed the code to this
<tr>
<td height="10" bgcolor="#422c13" style="background-color:#422c13;height:10px;font-size:1px;line-height:0; -webkit-text-size-adjust:none;"> </td>
</tr>
The background color still does not display.
I hate to do it but dam spacer images again...... i thought we were past that point.
Instead of adding a whole new empty/spacer image row, you can use CSS padding on the top and/or bottom row's TDs.
@brian you can use padding which is working with <td> or add this css style: font-size: 0; line-height: 0;
Thanks
the line-height needs to be the same as the height, not 0.
<tr height="20">
<td height="20" style="font-size:1px;line-height:20;"> </td>
</tr>
I had this issue too. Looks like sie and line-height must match the height or be 1 for both. Is that what you found to work best?
Have you resolved this without using spacer images? I am having exactly the same issue with outlook 2016:
<tr>
<td height="40" style="font-size: 0; line-height: 0;"> </td>
</tr>
Thanks Tricia
Kindly used below source code:
It might be helps you.
Thank you! This worked for me. Is it the -webkit-tetx-size-adjust rule making this stick?