This has got to be one of the strangest things I have ever encountered in my years coding HTML and CSS. This is specifically in regards to computers running Windows at 125% in display settings (i.e. DPI) and with Outlook 2010. (In my cases I'm running Windows 7)
I have two identical tables. Each with one row and one column, and each contains one image. If my code contains align=center, or if it does not contain align=left or right, the image will not scale up appropriately on a computer with Outlook 2010 that is at 125% dpi.
<table> <tr> <td> <img src="image.png" align="left"> </td> </tr> </table> <table> <tr> <td> <img src="image.png" align="center"> </td> </tr> </table>
Even using the following code, it doesn't fix the issue:
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office"> <head> <!--[if gte mso 9]><xml> <o:OfficeDocumentSettings> <o:AllowPNG/> <o:PixelsPerInch>96</o:PixelsPerInch> </o:OfficeDocumentSettings> </xml><![endif]--> </head>
Does this make any sense to anyone? I've searched all over and I can't seem to find anyone with any sort of similar issue, anywhere. It seems to boil down specifically to the align attribute -- without it set to left or right, the image will not scale appropriately.
Oh, and even if I put the align="center" in the TD that houses the image; no dice. Still causes it to not scale accordingly.
Now, of course, this does work perfectly in any web browser, or even in Outlook 2010 if the user is at 100%. But at 125% it just doesn't work, and seems to hinge on the align attribute.
Any help here... I would be so grateful. Is this even a known issue? I'm aware of the issues with Outlook using Word to render HTML, and with its DPI issues, etc. but I have yet to stumble across this specifically. Is there even a way to center my content while keeping the image scaling working?
From Australia to Zimbabwe, and everywhere in between, companies count on Campaign Monitor for email campaigns that boost the bottom line.Get started for free