Posted By

mjenos on 04/04/12


Tagged

email Email-Template


Versions (?)

Who likes this?

2 people have marked this snippet as a favorite

mjenos
spee66


Applying background images to Table Cells - Blog - Campaign Monitor


 / Published in: HTML
 

  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns:v="urn:schemas-microsoft-com:vml">
  3. <head>
  4.  
  5.  
  6. <table width="600" cellpadding="0" cellspacing="0" border="0">
  7.   <tr>
  8.     <!-- Backup background color is #DDDDDD -->
  9.     <td bgcolor="#DDDDDD" style="background-image: url('http://www.example.com/background_image.jpg');" background="http://www.example.com/background_image.jpg" width="600" height="120" valign="top">
  10.     <!--[if gte mso 9]>
  11.        <v:rect style="width:600px;height:120px;" strokecolor="none">
  12.           <v:fill type="tile" color="#DDDDDD" src="http://www.example.com/background_image.jpg" /></v:fill>
  13.        </v:rect>
  14.        <v:shape id="theText" style="position:absolute;width:600px;height:120px;">
  15.        <![endif]-->
  16.     <p>If you can see this over the image, background images are successful.</p>
  17.     <!--[if gte mso 9]>
  18.        </v:shape>
  19.     <![endif]--></td>
  20.   </tr>
  21. </table> 

Report this snippet  

You need to login to post a comment.