6 Replies - 1976 Views - Last Post: 08 September 2010 - 12:40 AM

#1 o2o  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 7
  • Joined: 06-September 10

HTML not rendering correctly in email

Posted 06 September 2010 - 09:17 PM

Hi guys,

i'm working on a newsletter that i will be sending out to clients, it works like a charm if i preview it in the website, however it doesn't look good in the email.

to make it clearer, i attached 2 jpg files, good and bad

good
Attached Image

and in the "bad" file
Attached Image
u'll notice a small black gap between "Miss us" and "its been a while....", while in the "good" file it is flawless.

Been tryin to figure this out for a few days now but still unable to track down the problem

i really appreciate your help

Here is the code


<html xmlns="http://www.w3.org/1999/xhtml"> 
<head> 
<title>E-Hope</title> 
<style type="text/css"> 
span {
	line-height: 22px;
}
</style> 
</head> 
<body bgcolor="#000"> 
<table width="100%" border="0" cellspacing="0" cellpadding="0"> 
  <tr> 
    <td align="center" bgcolor="#000000"><table width="558" border="0" cellpadding="0" cellspacing="0" bgcolor="#fff"> 
      <tr> 
        <td colspan="5" align="left" valign="top"></td> 
      </tr> 
       <tr> 
        <td colspan="5" align="center" valign="top" height="381"><img src="header_9.jpg" width="558" height="381"></td> 
      </tr> 
      <tr> 
        <td width="22" rowspan="5" align="right" bgcolor="#000000"></td> 
        <td width="7" rowspan="5" align="right" bgcolor="#434343"></td> 
        <td width="509" align="center" bgcolor="#FFFFFF"> 
        <table width="478" border="0" cellspacing="5" cellpadding="0"> 
        <tr> 
              <td height="80" colspan="2" align="left" valign="top" style="font-family:Georgia, 'Times New Roman', Times, serif;font-size:12px;color:#4d4b4b;line-height:22px;" ><em> It&rsquo;s been a while since our last chat, but we&rsquo;ve been saving up the good stuff for you. News of our partnership with Hollard, our Taschen book debut and a thrilling glimpse of the web in the future. Dig in and enjoy:
              </em></td> 
            </tr> 
        </table></td> 
                <td width="7" height="515" rowspan="5" align="left" valign="top" bgcolor="#434343"></td> 
        <td width="13" rowspan="5" align="left" valign="top" bgcolor="#000000"></td> 
      </tr> 
      </table>
      </td>
      </tr>
      </table>
      </body>
      </html>



Thank you!

Is This A Good Question/Topic? 0
  • +

Replies To: HTML not rendering correctly in email

#2 Dormilich  Icon User is online

  • 痛覚残留
  • member icon

Reputation: 3541
  • View blog
  • Posts: 10,226
  • Joined: 08-June 10

Re: HTML not rendering correctly in email

Posted 06 September 2010 - 10:45 PM

I suppose its due to the table layout. email clients are not browsers, after all. some people also may see nothing at all due to having HTML stripped down or even disabling it at all.
Was This Post Helpful? 0
  • +
  • -

#3 RudiVisser  Icon User is offline

  • .. does not guess solutions
  • member icon

Reputation: 1003
  • View blog
  • Posts: 3,562
  • Joined: 05-June 09

Re: HTML not rendering correctly in email

Posted 07 September 2010 - 05:09 AM

As mentioned above, email clients arn't browsers (unless you use Thunderbird, Opera, etc).

I'll assume that you're viewing the email in Outlook/Windows Live, am I correct?? If so then it's important to note that it's not a real renderer at all, it uses the Word rendering engine (which is crap).

Although I'm not sure of your exact problem, make sure that you're not using CSS anywhere and you should be fine.
Was This Post Helpful? 0
  • +
  • -

#4 o2o  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 7
  • Joined: 06-September 10

Re: HTML not rendering correctly in email

Posted 07 September 2010 - 05:24 AM

thats correct im using windows live hotmail.. well then ill modify the codes.

thanks for the input!
Was This Post Helpful? 0
  • +
  • -

#5 RudiVisser  Icon User is offline

  • .. does not guess solutions
  • member icon

Reputation: 1003
  • View blog
  • Posts: 3,562
  • Joined: 05-June 09

Re: HTML not rendering correctly in email

Posted 07 September 2010 - 05:36 AM

Sorry, I just did some confirmation on what I said and it seems I was lying. Windows Live Mail does render some HTML, it seems to be a minimal version of IE used in it, doesn't have full capabilities though.

However I was correct with Outlook, so it's best, for now, to stick to good old HTML4-style tables.

Just wanted to clarify it a bit.
Was This Post Helpful? 0
  • +
  • -

#6 o2o  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 7
  • Joined: 06-September 10

Re: HTML not rendering correctly in email

Posted 07 September 2010 - 09:10 PM

Hi, thanks for that. But anyway i managed to fix the problem, i simply changed the codes into something like this
<td width="262"><img src="" style="width:100%; height:100%;">



that way the image will be automatically fit into the size of the td

thanks for ur help!
Was This Post Helpful? 0
  • +
  • -

#7 RudiVisser  Icon User is offline

  • .. does not guess solutions
  • member icon

Reputation: 1003
  • View blog
  • Posts: 3,562
  • Joined: 05-June 09

Re: HTML not rendering correctly in email

Posted 08 September 2010 - 12:40 AM

No problem; Sorry that what I said was completely irrelevant! :)
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1