Skip to content

Instantly share code, notes, and snippets.

@fdanielsen
Last active May 10, 2024 14:50
Show Gist options
  • Save fdanielsen/d8af1f4dab0534140705660c1bc8800a to your computer and use it in GitHub Desktop.
Save fdanielsen/d8af1f4dab0534140705660c1bc8800a to your computer and use it in GitHub Desktop.
Very basic HTML email base
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width,initial-scale=1.0" />
<title>[subject]</title>
<style type="text/css">
/* E-mail Reset */
#outlook a{padding:0;}
body{width:100% !important;} .ReadMsgBody{width:100%;} .ExternalClass{width:100%;}
body{-webkit-text-size-adjust:none; -ms-text-size-adjust:none;}
body{margin:0; padding:0;}
img {outline:none; text-decoration:none;-ms-interpolation-mode: bicubic;}
a img {border:0;}
#backgroundTable{height:100% !important; margin:0; padding:0; width:100% !important;}
table td {border-collapse:collapse;}
table { border-collapse:collapse; mso-table-lspace:0pt; mso-table-rspace:0pt; }
@media only screen and (max-width: 480px) {
.auto-width {
width: auto !important;
}
.full-width {
width: 100% !important;
}
}
</style>
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" style="color:#434343;background-color: #ffffff; margin: 0; padding: 0">
<table width="100%" height="100%" cellpadding="0" cellspacing="0" border="0" id="backgroundTable" style="background-color: #ffffff;color:#434343">
<tr>
<td align="center">
<table class="full-width" width="500" cellpadding="0" cellspacing="0" border="0" style="color: #888888;">
</table>
</td>
</tr>
</table>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment