Created
August 27, 2011 14:36
-
-
Save johnhunter/1175458 to your computer and use it in GitHub Desktop.
TextMate snippet: table cell background (html email)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- | |
Don't forget to add: | |
<html xmlns:v="urn:schemas-microsoft-com:vml"> | |
--> | |
<!--[if gte mso 9]> | |
<v:image xmlns:v="urn:schemas-microsoft-com:vml" style='behavior: url(#default#VML); | |
display: inline-block; | |
position: absolute; | |
height: ${1:100}px; | |
width: ${2:100}px; | |
top: 0; | |
left: 0; | |
border: 0; | |
z-index: 1;' | |
src="${3:image-url}"/> | |
<v:shape xmlns:v="urn:schemas-microsoft-com:vml" style='behavior: url(#default#VML); | |
display: inline-block; | |
position: absolute; | |
height: $1px; | |
width: $2px; | |
top: -5; | |
left: -10; | |
border: 0; | |
z-index: 2;'> | |
<div> | |
<![endif]--> | |
${4:All of your content that will be floating over the background image.} | |
<!--[if gte mso 9]> | |
</div> | |
</v:shape> | |
<![endif]--> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
TextMate snippet for adding
background
images to table cells for Outlook. Uses a vml hack to absolutely position elements under the content.