Email signature not rendering correctly in Gmail and Hotmail

Hi everyone,

I have an email signature (see code below) that works fine in desktop email clients but I've noticed that Gmail and Hotmail are adding extra space at the top of the two td cells that contain the address and phone numbers and also extra space at the bottom of the cell that contains the image. I've used inline css to remove all margins from the td elements but it hasn't helped.

I wondered if someone could tell me if there's any fix for this so these two email clients will render it correctly.

Appreciate any help.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>Unititled</title>
<meta http-equiv="Content-Type" content="text/html;">
</head>
<body bgcolor="#ffffff" style="margin: 0; padding: 0;">
<!-- Start Table -->
<table width="330" height="100%" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" style="margin: 0;">
<tr>
<!-- Start Content -->
<td colspan="2" align="left" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 12px; line-height: 15px;  color:#000; padding: 0; margin: 0;"><p style="margin: 0; padding: 0;">Yours sincerely,<br /><br />
  <span style="font-weight:bold">Firstname Lastname</span>
  </p>
  <br /></td>
<!-- End Content -->
      </tr>
      
<tr>
  <td colspan="4" height="30" valign="middle" style="text-align:left; border-bottom: 1px solid #E5AF51; margin: 0; padding-bottom: 5px"><img src="logo.jpg" alt="Logo" width="160" height="30" /></td>
  </tr>
<tr>
 
 
<!-- Start Footer -->
            
 
        <td width="160" valign="top" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 15px; text-align:left; color:#666666; margin: 0; padding-top:5px;">Unit 5 <br />
2 Bligh Street<br />
Suburb NSW 2001 </td>
        
        <td width="170" valign="top" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 15px; text-align:left; color:#666666; margin: 0; padding-top:5px;"><span style="color: #000; font-weight:bold">T:</span> +61 2 9513 0000 <br />
     <span style="color: #000; font-weight:bold">F:</span> +61 2 9516 0000 <br />
     <span style="color: #000; font-weight:bold">W: </span><a href="http://www.newsite.com.au" style="text-decoration:none; color:#666666;">www.newsite.com.au</a></td>
        <!-- End Footer -->
  </tr>
</table>
</body>
</html>

Open in new window

LVL 1
gwh2Asked:
Who is Participating?
 
hieloConnect With a Mentor Commented:
>>Do you know what might be happening?
IF what you posted renders as YOU want it when you test it by itself, then most likely there are style definitions in gmail that is affecting your design. You would need to look at the css of gmail and figure which one of those is affecting your design. For example, if gmail has a something like:
td{background-color:green;}

and you don't want that, then you would need to override that in YOUR html.
0
 
hieloCommented:
Try:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>Unititled</title>
<meta http-equiv="Content-Type" content="text/html;">
</head>
<body bgcolor="#ffffff" style="margin: 0; padding: 0;">
<!-- Start Table -->
<table width="330" height="100%" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" style="margin: 0;">
<tr>
<!-- Start Content -->
<td colspan="2" align="left" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 12px; line-height: 15px;  color:#000; padding: 0; margin: 0;"><p style="margin: 0; padding: 0;">Yours sincerely, 

  <span style="font-weight:bold">Firstname Lastname</span>
  </p>
  
</td>
<!-- End Content -->
??????</tr>
??????
<tr>
  <td colspan="4" height="30" valign="middle" style="text-align:left; border-bottom: 1px solid #E5AF51; margin: 0; padding-bottom: 5px"><img src="logo.jpg" alt="Logo" width="160" height="30" /></td>
  </tr>
<tr>
 
 
<!-- Start Footer -->
            
 
        <td width="160" valign="top" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align:left; color:#666666; margin: 0px; padding:0px !important;;">Unit 5  
2 Bligh Street 
Suburb NSW 2001 </td>
        
        <td width="170" valign="top" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align:left; color:#666666; margin: 0; padding:0px !important;"><span style="color: #000; font-weight:bold">T:</span> +61 2 9513 0000  
     <span style="color: #000; font-weight:bold">F:</span> +61 2 9516 0000  
     <span style="color: #000; font-weight:bold">W: </span><a href="http://www.newsite.com.au" style="text-decoration:none; color:#666666;">www.newsite.com.au</a></td>
        <!-- End Footer -->
  </tr>
</table>
</body>
</html>

Open in new window

0
 
gwh2Author Commented:
Thanks for replying,

I'm not sure what you did  the only thing I can see that you added is:

<!-- End Content -->
??????</tr>
??????
<tr>

can you explain?
0
Take Control of Web Hosting For Your Clients

As a web developer or IT admin, successfully managing multiple client accounts can be challenging. In this webinar we will look at the tools provided by Media Temple and Plesk to make managing your clients’ hosting easier.

 
gwh2Author Commented:
Alli it does is add a whole bunch of question marks below the name. Any other suggestions?
0
 
hieloCommented:
Those question marks were added by the browser, not me. I removed padding-top and also line-height from the original post. Not sure why those question marks were added but you need to get rid of them.
0
 
gwh2Author Commented:
Hi,

I removed the padding and line-height and also used !important where you used it. When I tested the problem is still persisting. My revised code is below.

Do you know what might be happening?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>Unititled</title>
<meta http-equiv="Content-Type" content="text/html;">
</head>
<body bgcolor="#ffffff" style="margin: 0; padding: 0;">
<!-- Start Table -->
<table width="330" height="100%" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" style="margin: 0;">
<tr>
<!-- Start Content -->
<td colspan="2" align="left" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 12px; line-height: 15px;  color:#000; padding: 0; margin: 0;"><p style="margin: 0; padding: 0;">Yours sincerely,<br /><br />
  <span style="font-weight:bold">Firstname Lastname </span>
  </p>
  <br /></td>
<!-- End Content -->
</tr>
<tr>
  <td colspan="4" height="30" valign="middle" style="text-align:left; border-bottom: 1px solid #E5AF51; margin: 0; padding-bottom: 5px"><img src="logo.jpg" alt="Logo" width="160" height="30" /></td>
  </tr>
<tr>
 
 
<!-- Start Footer -->
            
 
        <td width="160" valign="top" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align:left; color:#666666; margin: 0 !important; padding: 0 !important;">Unit 5<br />
2 Bligh Street<br />
Suburb NSW 2001 </td>
        
        <td width="170" valign="top" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align:left; color:#666666; margin: 0 !important; padding: 0 !important;"><span style="color: #000; font-weight:bold">T:</span> +61 2 9513 0000 <br />
     <span style="color: #000; font-weight:bold">F:</span> +61 2 9513 0000 <br />
     <span style="color: #000; font-weight:bold">W: </span><a href="http://www.newsite.com.au" style="text-decoration:none; color:#666666;">www.newsite.com.au</a></td>
        <!-- End Footer -->
  </tr>
</table>
</body>
</html>

Open in new window

0
 
gwh2Author Commented:
I was saying in my original post that there was a problem with extra space in Gmail and I understand that Gmail must have certain css definitions such as putting extra space after paragraphs etc. and that is why I added the !important rules to my css to override it, eg.

        <td width="160" valign="top" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; text-align:left; color:#666666; margin: 0 !important; padding: 0 !important;">Unit 5<br />
2 Bligh Street<br />
Suburb NSW 2001 </td>

...but it hasn't helped which is why I'm asking for help. Do you know why the extra space is continuing even after adding the !important rule?
0
 
gwh2Author Commented:
Hi,

I found that these spacing problems are only occurring in the Gmail and Hotmail on a mac computer - they don't seem to be a problem on the pc side, so I guess it's a mac issue.
0
All Courses

From novice to tech pro — start learning today.