<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-4086249908856332456</id><updated>2011-11-17T14:02:39.321-05:00</updated><category term='Coding'/><category term='File Size'/><category term='Doctype'/><category term='Email'/><category term='CSS'/><category term='Standards'/><category term='Images'/><category term='Validation'/><category term='HTML'/><category term='XHTML'/><category term='Forms'/><category term='JavaScript'/><category term='Photoshop'/><title type='text'>EmailElements - Blogging all about HTML Email Standards, CSS and XHTML</title><subtitle type='html'>Blogging regularly about HTML Email standards coding and how to get your email looking great in all clients. Plus a few CSS and XHTML insights I gather along the way.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://mikekleiman.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://mikekleiman.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Mike Kleiman</name><uri>http://www.blogger.com/profile/04730089168344499371</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>8</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-4086249908856332456.post-7762587683217832037</id><published>2008-01-22T14:08:00.001-05:00</published><updated>2008-01-22T14:46:45.759-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Email'/><category scheme='http://www.blogger.com/atom/ns#' term='CSS'/><category scheme='http://www.blogger.com/atom/ns#' term='HTML'/><title type='text'>CSS Hover in HTML Email... is it possible???</title><content type='html'>I had an idea today, would it be possible to use the CSS hover technique to create some kind of JavaScript rollover replacement for Email. I wasn't looking for your typical link hover effect or a mouseover effect on an image, my concern was more along the lines of: you have a link, and when you mouse over it can you expand the area to show more text beneath it.&lt;br /&gt;&lt;br /&gt;This could be quite useful when you consider it's implications in scenarios like the following: You have a paragraph long intro to a story that ends with a "more" link leading you to the full version of the story somewhere on the web.  What if vertical resources were sparse and you needed to condense this? Not only would you be able to condense it using hover, the whole paragraph then becomes a clickable link to the full story... or perhaps even more useful... rollover text ads that expand to show skyscrapers and then contract again to just the text, allowing you to perhaps include more ads while in actuality using less space!&lt;br /&gt;&lt;br /&gt;So with this in mind I set about testing all the clients and browsers I could with the following &lt;a href="http://www.dotslashmk.com/experimental/hoveremail/"&gt;VERY simple code&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;I know right away this won't work in Gmail, since hover cannot be applied inline and Gmail cuts out the style block. But it's still worth an experimentation anyways since I found Gmail simply defaulted to show the entire content and so even when it breaks the user is still getting essentially the full experience.&lt;br /&gt;&lt;br /&gt;My results for browsers were as follows:&lt;br /&gt;&lt;br /&gt;&lt;b&gt;WINDOWS XP SP2&lt;/b&gt;&lt;br /&gt;&lt;i&gt;DESKTOP CLIENTS&lt;/i&gt;&lt;br /&gt;&lt;i&gt;Working&lt;/i&gt;&lt;br /&gt;Outlook 2003&lt;br /&gt;Outlook Express&lt;br /&gt;Thunderbird&lt;br /&gt;Eudora&lt;br /&gt;Incredimail&lt;br /&gt;Opera&lt;br /&gt;&lt;br /&gt;&lt;i&gt;WEB CLIENTS - Internet Explorer 7 &amp;amp; Firefox 2&lt;/i&gt;&lt;br /&gt;&lt;i&gt;Working&lt;/i&gt;&lt;br /&gt;AIM Mail&lt;br /&gt;Excite&lt;br /&gt;Hotmail Live&lt;br /&gt;Hotmail Classic&lt;br /&gt;Yahoo Classic&lt;br /&gt;&lt;br /&gt;&lt;i&gt;Not Working But Degrades Well&lt;/i&gt;&lt;br /&gt;Gmail&lt;br /&gt;&lt;br /&gt;&lt;b&gt;MAC OS X 10.4&lt;/b&gt;&lt;br /&gt;&lt;i&gt;DESKTOP CLIENTS&lt;/i&gt;&lt;br /&gt;&lt;i&gt;Working&lt;/i&gt;&lt;br /&gt;Entourage&lt;br /&gt;Mac Mail&lt;br /&gt;&lt;br /&gt;So as you can see these are totally encouraging results! This basically means that no matter what the scenario you use this technique in, even if it fails the user will still see your content.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4086249908856332456-7762587683217832037?l=mikekleiman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mikekleiman.blogspot.com/feeds/7762587683217832037/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4086249908856332456&amp;postID=7762587683217832037&amp;isPopup=true' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/7762587683217832037'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/7762587683217832037'/><link rel='alternate' type='text/html' href='http://mikekleiman.blogspot.com/2008/01/css-hover-in-html-email-is-it-possible.html' title='CSS Hover in HTML Email... is it possible???'/><author><name>Mike Kleiman</name><uri>http://www.blogger.com/profile/04730089168344499371</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4086249908856332456.post-346872258313745241</id><published>2008-01-11T11:30:00.001-05:00</published><updated>2008-01-22T14:51:54.383-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Standards'/><category scheme='http://www.blogger.com/atom/ns#' term='Photoshop'/><category scheme='http://www.blogger.com/atom/ns#' term='Email'/><category scheme='http://www.blogger.com/atom/ns#' term='Coding'/><category scheme='http://www.blogger.com/atom/ns#' term='HTML'/><title type='text'>Coding an HTML Email in 3 Easy Steps : Part 3</title><content type='html'>Ok we're finally ready to code! We've looked at the email from the "big picture" angle, and we've looked at the proper ways of cutting up the images.  So now we have an images folder full of pretty pictures and a blank document open in our favourite text editor (UltraEdit for me incase you're wondering). So how do we start? Well, I usually like to start by having a pre-defined template that serves as the base for my emails.  It has the basic structure and I can use it to start coding from right away.  This works for new emails, however if you're simply creating a new edition of an older email, much like a monthly newsletter, I always always ALWAYS use the most recent version of code.  The reasons for this are two-fold.  One, there is much less coding needed if the format is always similar, it's mostly just an update the copy and links job and two, I am always updating code to stay ontop of developments in email clients.  So the last version used will always have my most recent fixes and mods and I won't have to worry about updating an older template that wasn't using newer techniques.&lt;br /&gt;&lt;br /&gt;Here's an example of a code snippet I use as a base template for starting with:&lt;br /&gt;&lt;br /&gt;&lt;hr noshade size="1" /&gt;&lt;br /&gt;&amp;lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"&lt;br /&gt;"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&amp;gt;&lt;br /&gt;&amp;lt;html&amp;gt;&lt;br /&gt;&amp;lt;body&amp;gt;&lt;br /&gt;&amp;lt;style&amp;gt;&lt;br /&gt;#cssshell a&lt;br /&gt;{&lt;br /&gt; font-family:Verdana,Tahoma,Arial,Helvetica,Sans-Serif;font-size:12px;color:#CE482F;&lt;br /&gt;}&lt;br /&gt;#cssshell td&lt;br /&gt;{&lt;br /&gt; text-align:left;&lt;br /&gt;}&lt;br /&gt;&amp;lt;/style&amp;gt;&lt;br /&gt;&amp;lt;table width="600" border="0" cellspacing="0" cellpadding="0" id="cssshell"&amp;gt;&lt;br /&gt;  &amp;lt;tr&amp;gt;&lt;br /&gt;    &amp;lt;td&amp;gt;    &amp;lt;/td&amp;gt;&lt;br /&gt;  &amp;lt;/tr&amp;gt;&lt;br /&gt;&amp;lt;/table&amp;gt;&lt;br /&gt;&amp;lt;a name="bottom"&amp;gt;&amp;lt;/a&amp;gt;&lt;br /&gt;&amp;lt;/body&amp;gt;&lt;br /&gt;&amp;lt;/html&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;hr noshade size="1" /&gt;&lt;br /&gt;I'm not going to get into very precise coding techniques, as the purpose of this series is to give you overall method rather than individual technique.  However a few notes on the code above might be helpful, so...&lt;ul&gt;&lt;li&gt;As per my earlier article regarding doctypes, I now place a doctype at the top of all emails to ensure code is following standards in Outlook and Express&lt;/li&gt;&lt;li&gt;Always enclose the email in an open and close HTML set of tags, this lowers spam score&lt;/li&gt;&lt;li&gt;No need for the head tag, and always ensure the style block is placed BELOW the body tag&lt;/li&gt;&lt;li&gt;The overall link style is used because some clients will rewrite links using their default font/color&lt;/li&gt;&lt;li&gt;The td alignment fix was used for issues in Hotmail live wherein a centered table would force all internal cells to be aligned center as well, I have yet to test if newer versions of Hotmail Live still cause this problem, but as a safegaurd I always leave this in&lt;/li&gt;&lt;li&gt;A complete table, with an ID of cssshell to ensure the style block is used on this table only, if you use overriding styles with no ID attribute you run the risk of styling the entire interface of a webmail client&lt;/li&gt;&lt;/ul&gt;&lt;hr noshade size="1" /&gt;&lt;br /&gt;You're now ready to start coding and laying out tables to your hearts content.  I always use the ideology that less is more when I code for email. Keeping code size down will allow you to keep bandwidth costs down for your clients as well as speed up delivery. Even a few kb's lower in file size has massive implications on mailing lists with millions of recipients.&lt;br /&gt;&lt;br /&gt;So as we start coding I always find it’s helpful to have the PSD open as well as your new HTML document so that you can reference the layout as your working, it gives you a good idea of how to look at your code in a visual way and you can start to see how everything will translate into table cells, speaking of tables...&lt;br /&gt;&lt;br /&gt;Tables, it’s all about tables, sure they aren’t the latest web standards but it’s the only way to layout an email easily while ensuring it works in as many clients as possible, so use them instead of divs to place your content. I know it feels wrong... but believe me... you'll get much better results.&lt;br /&gt;&lt;br /&gt;Using CSS inline is the way to go when coding emails.  They work in all email clients as long as you avoid some pratfalls and unsupported elements. They also provide the most consistent branding by locking down things like font size which normally can be very sporadic if you leave it up to the &amp;lt;font size=""&amp;gt; tag and attribute. I know there is a school of thought in user design that we should make the font size and color open to user preference, by using style techniqes that utilize percentage rather than a fixed pixel width.  I'm not here to argue one case against the other... but I use pixel height as a precise measure because I look at emails as being a very precise, final medium.  They are not like a website, they do not change or get updated on a regular basis.  They get sent once and that's it, a person can look at it the first time and the hundredth time and they technically should still see the same thing. The only other medium that follows those rules is print, and print uses a fixed font height.  I realize that I did just argue for one side over the other... but well... it's my blog :)&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:11px;"&gt;&lt;i&gt;Coders - Always style table cells that enclose text with at least the font-family and font-size. Set line-height to normal unless you need specific line spacing as different web clients tend to interpret specific values differently. Always apply inline styles to links and wrap the link text itself in &amp;lt;font color=""&amp;gt;&amp;lt;/font&amp;gt; tags&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Well that about covers the basics for how to code an email from scratch. I hope you enjoyed it!&lt;br /&gt;&lt;br /&gt;Cheers&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4086249908856332456-346872258313745241?l=mikekleiman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mikekleiman.blogspot.com/feeds/346872258313745241/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4086249908856332456&amp;postID=346872258313745241&amp;isPopup=true' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/346872258313745241'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/346872258313745241'/><link rel='alternate' type='text/html' href='http://mikekleiman.blogspot.com/2008/01/coding-html-email-in-3-easy-steps-part_11.html' title='Coding an HTML Email in 3 Easy Steps : Part 3'/><author><name>Mike Kleiman</name><uri>http://www.blogger.com/profile/04730089168344499371</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4086249908856332456.post-3221263926814193137</id><published>2008-01-09T13:57:00.000-05:00</published><updated>2008-01-09T14:25:54.500-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Standards'/><category scheme='http://www.blogger.com/atom/ns#' term='Photoshop'/><category scheme='http://www.blogger.com/atom/ns#' term='Email'/><category scheme='http://www.blogger.com/atom/ns#' term='Coding'/><category scheme='http://www.blogger.com/atom/ns#' term='HTML'/><title type='text'>Coding an HTML Email in 3 Easy Steps : Part 2</title><content type='html'>&lt;img src="http://www.dotslashmk.com/experimental/makingemails/finished.jpg" alt="Machine Text" align="right" hspace="0" style="margin:0 0 10px 10px;" /&gt;So part one dealth more with big picture and at the end I discussed taking a wider view of the email and deciding what to do on a few &lt;a href="http://mikekleiman.blogspot.com/2008/01/coding-html-email-in-3-easy-steps-part.html"&gt;key points&lt;/a&gt;.  Ofcourse describing what to do isn't as useful as actually checking out a visual example so I've gone ahead and included a quick email mockup below and highlighted key things to look for when you do that big once over at the end of step one.  This will really help you figure out how to slice up your photoshop document so that you are getting maximum effect with minimum filesize.&lt;br /&gt;&lt;br /&gt;This is the finished product on the right, so let's start deconstructing it bit by bit.&lt;br /&gt;&lt;br style="clear:both;" /&gt;&lt;br /&gt;&lt;hr noshade size="1" /&gt;&lt;br /&gt;&lt;table border="0" cellpadding="0" cellspacing="0"&gt;&lt;tr&gt;&lt;td valign="top" style="padding-right:20px;"&gt;&lt;img src="http://www.dotslashmk.com/experimental/makingemails/machinetext.jpg" alt="Machine Text" /&gt;&lt;/td&gt;&lt;td valign="top"&gt;&lt;b&gt;MACHINE TEXT&lt;/b&gt;&lt;br /&gt;In the example to the left originally the words Win a cool prize pack... were graphic text, in this specific scenario the words were in a very unique font and therefore could not utilize machine text, but for the sake of example if they were in Arial or Helvetica or Verdana they could most likely take advantage of machine text.  So when you first open your PSD do a once over to see if there are any areas which can use this technique.&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;br /&gt;&lt;hr noshade size="1" /&gt;&lt;br /&gt;&lt;table border="0" cellpadding="0" cellspacing="0"&gt;&lt;tr&gt;&lt;td valign="top" style="padding-right:20px;"&gt;&lt;img src="http://www.dotslashmk.com/experimental/makingemails/slices.jpg" alt="Slice Areas" /&gt;&lt;/td&gt;&lt;td valign="top"&gt;&lt;b&gt;SLICE AREAS&lt;/b&gt;&lt;br /&gt;Highlighted in green are the areas that would make the best candidates for “slicing”. They are all pretty obvious and can usually be determined by whether the final product will be an image or use code/machine text.  Sometimes you will encounter drop shadows, these work just as a regular HTML background, you would slice 1px of height from a vertical drop shadow, use it as a cell background at which point it would then auto-repeat inside an expanding table cell.  It is useful to note however, that if you are expecting a large recipient base to be using Outlook 2007 it would be best to avoid this method and opt for one big dropshadow image.&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;br /&gt;&lt;hr noshade size="1" /&gt;&lt;br /&gt;&lt;table border="0" cellpadding="0" cellspacing="0"&gt;&lt;tr&gt;&lt;td valign="top" style="padding-right:20px;"&gt;&lt;img src="http://www.dotslashmk.com/experimental/makingemails/pixellines.jpg" alt="CSS Borders" /&gt;&lt;/td&gt;&lt;td valign="top"&gt;&lt;b&gt;CSS BORDERS&lt;/b&gt;&lt;br /&gt;It is a little hard to see in the example, but just above and below the main content area are two red highlighted areas.  These consist of simple 1px lines which can be achieved merely by setting either a border-bottom:1px solid #FFFFFF or border-top:1px solid #FFFFF.  This then ensures that even with images turned off, this element of the design will still be seen.&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;br /&gt;&lt;hr noshade size="1" /&gt;&lt;br /&gt;&lt;table border="0" cellpadding="0" cellspacing="0"&gt;&lt;tr&gt;&lt;td valign="top" style="padding-right:20px;"&gt;&lt;img src="http://www.dotslashmk.com/experimental/makingemails/padding.jpg" alt="CSS Padding" /&gt;&lt;/td&gt;&lt;td valign="top"&gt;&lt;b&gt;CSS PADDING&lt;/b&gt;&lt;br /&gt;One final thing to look for when scoping the PSD is, where can the email take advantage of CSS padding?  In the left you can see multiple areas highlighted in yellow.  These areas indicate places where using CSS padding will allow you to position elements properly within table cells.  For example in the left column in the main content area, there is no need to use pixels to space out content when a simple padding:20px; tag will push all elements inside that cell 20px inward away from all the edges. Same with the black border running around the entire email, all that needs to be is one big table cell with a black background that uses equal padding to push the entire table within it away from its edges.&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;br /&gt;&lt;hr noshade size="1" /&gt;&lt;br /&gt;Ok so we have now given the creative a good once over, and we've decided where we need to slice. You can then begin cutting up the PSD in Photoshop by creating slices using the slice tool. Make sure you cut as close to images as possible, as we can generally use padding or borders to space things out later, this cuts down on image size and let’s us do more in the code instead.&lt;br /&gt;&lt;br /&gt;It may also help at this point to be sure and give your slices relevant names.  This makes it easier once you save them by allowing you to tell which image came from where, what type of graphics it is (ie:image, header, text, etc...) and it also saves time having to rename everything later.&lt;br /&gt;&lt;hr noshade size="1" /&gt;&lt;br /&gt;&lt;table border="0" cellpadding="0" cellspacing="0"&gt;&lt;tr&gt;&lt;td valign="top" style="padding-right:20px;"&gt;&lt;img src="http://www.dotslashmk.com/experimental/makingemails/cutting.jpg" alt="Cutting Slices" /&gt;&lt;/td&gt;&lt;td valign="top"&gt;&lt;b&gt;CUT IT CLOSE&lt;/b&gt;&lt;br /&gt;The graphic on the right shows the incorrect way to cut an image (red highlight) and the correct way (green highlight).  Notice how the green highlight excludes all the extra space, letting the code do the work for us.&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;br /&gt;&lt;hr noshade size="1" /&gt;&lt;br /&gt;That's it, you're finally ready to save for web. When I get ready to start saving the images I like to keep the following in mind:&lt;ul&gt;&lt;li&gt;Generally images with multiple colors and less complexity (with regards to straight lines) are better served being saved as jpg’s where as flat text or portions that have few colors within them are better served by being a gif&lt;/li&gt;&lt;li&gt;Remember this is email, not the web, people want quick downloads, so make sure you cut down file size as much as possible while still retaining the best image quality you can, generally try and keep the masthead imagery looking sharp whereas smaller images within the email can suffer more as they are not responsible for initial impact&lt;/li&gt;&lt;/ul&gt;&lt;hr noshade size="1" /&gt;&lt;br /&gt;&lt;table border="0" cellpadding="0" cellspacing="0"&gt;&lt;tr&gt;&lt;td valign="top" style="padding-right:20px;"&gt;&lt;img src="http://www.dotslashmk.com/experimental/makingemails/imagetypes.jpg" alt="Image Types" /&gt;&lt;/td&gt;&lt;td valign="top"&gt;&lt;b&gt;IMAGE TYPES&lt;/b&gt;&lt;br /&gt;Notice how the images in the example have been divided up.  The masthead had multiple colors and the least amount of complex lines so it was best served as being a jpg whereas the rest all worked more efficiently as gifs.&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;br /&gt;&lt;hr noshade size="1" /&gt;&lt;br /&gt;Check back for part 3... coding!&lt;br /&gt;&lt;br /&gt;Cheers&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4086249908856332456-3221263926814193137?l=mikekleiman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mikekleiman.blogspot.com/feeds/3221263926814193137/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4086249908856332456&amp;postID=3221263926814193137&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/3221263926814193137'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/3221263926814193137'/><link rel='alternate' type='text/html' href='http://mikekleiman.blogspot.com/2008/01/coding-html-email-in-3-easy-steps-part_09.html' title='Coding an HTML Email in 3 Easy Steps : Part 2'/><author><name>Mike Kleiman</name><uri>http://www.blogger.com/profile/04730089168344499371</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4086249908856332456.post-7912905747259459611</id><published>2008-01-08T16:25:00.000-05:00</published><updated>2008-01-09T13:57:05.532-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Standards'/><category scheme='http://www.blogger.com/atom/ns#' term='Photoshop'/><category scheme='http://www.blogger.com/atom/ns#' term='Email'/><category scheme='http://www.blogger.com/atom/ns#' term='Coding'/><category scheme='http://www.blogger.com/atom/ns#' term='HTML'/><title type='text'>Coding an HTML Email in 3 Easy Steps : Part 1</title><content type='html'>Awhile back I decided to write out all the processes I go through when I sit down in front of a computer and get ready to code an email from scratch. I think I pretty much have my thought process down to a science now and I think it might be helpful to share it here, so over the next three days I'll post my overviews of each step along with the best practices that I use to ensure that I get the most readable email possible.&lt;br /&gt;&lt;br /&gt;Part one is all about the pre-production phase. It really helps to take a look at your creative as whole and go over how exactly you are going to slice that gorgeous design up to get the best reproduction possible in Gmail, Hotmail, Outlook and not Lotus Notes :) It's a short step and doesn't involve any technical knowledge, but I can't stress enough how important this first step is, as everything that happens in your code will come from the decisions you make in phase one.&lt;br /&gt;&lt;br /&gt;Let's get right to it then:&lt;br /&gt;&lt;br /&gt;&lt;b&gt;FOR COMPATIBILITY&lt;/b&gt;&lt;br /&gt;Even the best email campaign designs can fall flat if they are not coded properly. What may look stellar on the drawing board, and come to life further in Photoshop layers, can end up looking like an incoherent mess in the preview pane. With some background knowledge and adherence to best practices you can ensure that email recipients get the most out of our emails.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;JPG’S ARE THE LAST RESORT&lt;/b&gt;&lt;br /&gt;Sounds simple sure, but a lot of times Account Managers or Project Managers send you, the coder, jpgs. These are generally no good for coding. We need Photoshop Originals for three reasons:&lt;ul&gt;&lt;li&gt;We need to get the best quality possible for images and the only way to do that is to ensure the source we start from is of the best quality possible.&lt;/li&gt;&lt;li&gt;We must ensure that we can turn elements “on” and “off” using layer visibility incase there are elements that are obstructed.&lt;/li&gt;&lt;li&gt;If no copy deck exists, the Photoshop document becomes the source for our copy, and we need to be able to copy-and-paste from it into our HTML code.&lt;/li&gt;&lt;/ul&gt;&lt;span style="font-size:11px;"&gt;&lt;i&gt;Designers - Ensure your layers are grouped relevantly and named appropriately so that they can be easily understood by a coder&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;b&gt;SEEING THE BIGGER PICTURE&lt;/b&gt;&lt;br /&gt;Again it all sounds very simple, but this is actually the most important step of the three. Give the overall design a once over and try to make at least some general decisions about the following: &lt;ul&gt;&lt;li&gt;What areas should remain as imagery and what areas can utilize machine text&lt;/li&gt;&lt;li&gt;Where will your slices work most effectively to reduce the amount actual pixels used in an image&lt;/li&gt;&lt;li&gt;Are there any straightforward simple lines that could benefit from using CSS borders instead of a stretched 1 pixel image&lt;/li&gt;&lt;li&gt;Where can you utilize padding so that you don’t include any unnecessary pixels in your slices or use the 90’s old school technique of pixel-spacers&lt;/li&gt;&lt;/ul&gt;&lt;span style="font-size:11px;"&gt;&lt;i&gt;Designers - Try to ensure that any text that can be machine text is, and is not anti-aliased, since generally a client approves a design flat, not a coded flat, and differences in subtleties such as anti-aliasing on text can cause disagreements&lt;/i&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;That's it for part one. Tomorrow I'll follow-up some graphical examples and we'll get into part 2, which involves cutting up the design and getting ready to code, and then we'll end with part 3... the actual coding!&lt;br /&gt;&lt;br /&gt;Cheers&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4086249908856332456-7912905747259459611?l=mikekleiman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mikekleiman.blogspot.com/feeds/7912905747259459611/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4086249908856332456&amp;postID=7912905747259459611&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/7912905747259459611'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/7912905747259459611'/><link rel='alternate' type='text/html' href='http://mikekleiman.blogspot.com/2008/01/coding-html-email-in-3-easy-steps-part.html' title='Coding an HTML Email in 3 Easy Steps : Part 1'/><author><name>Mike Kleiman</name><uri>http://www.blogger.com/profile/04730089168344499371</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4086249908856332456.post-5758907196707212319</id><published>2007-12-20T14:47:00.001-05:00</published><updated>2007-12-20T15:52:44.932-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Standards'/><category scheme='http://www.blogger.com/atom/ns#' term='Doctype'/><category scheme='http://www.blogger.com/atom/ns#' term='XHTML'/><category scheme='http://www.blogger.com/atom/ns#' term='Email'/><category scheme='http://www.blogger.com/atom/ns#' term='HTML'/><title type='text'>Using DOCTYPE in an Email</title><content type='html'>The other day a co-worker brought up a good point, what happens when you include or exclude a DOCTYPE from an email code? I hadn't really given the issue much thought seeing as how most web clients simply strip out anything above the HTML element anyways, but I decided it was atleast worth a test... and I came back with a different take on the whole concept.  DOCTYPE makes a big difference in some major clients, most notably Outlook 2003.  I'm going to post my full review soon along with my test case, but as a brief rundown I've compiled the brief list below testing this code in both &lt;a href="http://www.dotslashmk.com/experimental/doctypetest/standards.html"&gt;standard&lt;/a&gt; and &lt;a href="http://www.dotslashmk.com/experimental/doctypetest/quirks.html"&gt;quirks&lt;/a&gt; mode. You can clearly see the difference in both in Internet Explorer, unfortunately no difference is visible in Firefox, but as I said, this was merely an initial test.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;On Windows XP SP 2:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;Affected&lt;/span&gt;&lt;br /&gt;Outlook 2003&lt;br /&gt;Outlook Express&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;Rendered in Standards Mode&lt;/span&gt;&lt;span style="font-style: italic;"&gt; Regardless of Existence of DOCTYPE&lt;/span&gt;&lt;br /&gt;Thunderbird v1.8 (not conclusive as it may have been using FireFox's quirks mode, requires further tests)&lt;br /&gt;Eudora v7&lt;br /&gt;IncrediMail XE&lt;br /&gt;Opera 9&lt;br /&gt;&lt;br /&gt;I'm thinking that since the Outlooks are the only 2 desktop solutions that use IE as a rendering engine this makes sense.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;On the Web in Internet Explorer 7:&lt;br /&gt;&lt;/span&gt;&lt;span style="font-style: italic;"&gt;Affected&lt;/span&gt;&lt;br /&gt;None&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;Rendered in Standards Mode Regardless of Existence of DOCTYPE&lt;br /&gt;&lt;/span&gt;Gmail&lt;br /&gt;Hotmail Live and Classic&lt;br /&gt;&lt;span style="font-style: italic;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="font-style: italic;"&gt;Rendered in Quirks Mode&lt;/span&gt;&lt;span style="font-style: italic;"&gt; Regardless of Existence of DOCTYPE&lt;/span&gt;&lt;br /&gt;AIM Mail&lt;br /&gt;Excite&lt;br /&gt;Yahoo New and Classic&lt;br /&gt;&lt;br /&gt;The standards mode rendering seemed a bit off to me, since Gmail strips the doctype, but it must be applying its own standard to all code within the email preview area.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;On the Web in Firefox 2:&lt;br /&gt;&lt;/span&gt;Same as above, but results will obviously appear differently since FireFox's quirks mode is significantly different that IE's.&lt;br /&gt;&lt;br /&gt;I went ahead and made the assumption from these two tests that all the webmail clients will behave the same in all browsers, leaving it up quirks mode to define AOL, Excite and the two Yahoos, and defining a doctype for Google and the two Hotmails.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;On a Mac&lt;/span&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;Affected&lt;/span&gt;&lt;br /&gt;Mac Mail&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;Unaffected&lt;/span&gt;&lt;br /&gt;Entourage&lt;br /&gt;&lt;br /&gt;I am guessing Mail must be similar to Outlook in that it uses Safari to render HTML emails.  I'll have a more in-depth review coming up after the holidays, but from what I can tell so far, putting the DOCTYPE in doesn't actually do harm, if anything it helps ensure you're rendering to compliance spec in Outlook and Mac Mail... however the downside is since all web clients seem to disregard it or use their own DOCTYPE standard you have to pretty much code for both. Don't you love coding for email? :)&lt;br /&gt;&lt;br /&gt;Cheers&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4086249908856332456-5758907196707212319?l=mikekleiman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mikekleiman.blogspot.com/feeds/5758907196707212319/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4086249908856332456&amp;postID=5758907196707212319&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/5758907196707212319'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/5758907196707212319'/><link rel='alternate' type='text/html' href='http://mikekleiman.blogspot.com/2007/12/using-doctype-in-email.html' title='Using DOCTYPE in an Email'/><author><name>Mike Kleiman</name><uri>http://www.blogger.com/profile/04730089168344499371</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4086249908856332456.post-9159300301156719646</id><published>2007-12-18T14:05:00.000-05:00</published><updated>2007-12-20T13:09:22.189-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='JavaScript'/><category scheme='http://www.blogger.com/atom/ns#' term='XHTML'/><category scheme='http://www.blogger.com/atom/ns#' term='Forms'/><category scheme='http://www.blogger.com/atom/ns#' term='Validation'/><title type='text'>XHTML Compliant JavaScript Form Validator</title><content type='html'>So I have been working on a javascript form validation system for awhile that would be suitable to be dropped into just about scenario. Sure there are already solutions out there like the TMT validator, but it doesn't validate XHTML.&lt;br /&gt;&lt;br /&gt;During my day to day I work on alot of .NET projects where there are loads of back-end validations going on. Besides the fact that I have to deal with server rendered form elements I also I personally try to avoid using the built in JavaScript validation that MS provides.  It's buggy.. and very.. Microsoft.&lt;br /&gt;&lt;br /&gt;So I needed something that would validate XHTML Transitional as well as be simple to implement in any coding environment, and voila, a week later here it is in it's very beta version. I tried to think of every validation that might ever be required on a web form. It has plenty of simple customizations, such as specifying particular country validations on phone numbers and postal codes, as well as allowing a couple of methods for error display.  All of these customizations can obviously be expanded by any coder with moderate JavaScript understanding, so this might be a good base for others to start from.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.dotslashmk.com/experimental/formvalidator/" target="_blank"&gt;&lt;b&gt;Check out the XHTML Compliant JavaScript Form Validator here&lt;/b&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;If you can think of any way to optimize this, without bulking up the code too much, or any validations that might be a necessity please let me know or leave a comment.&lt;br /&gt;&lt;br /&gt;The instructions are on the same page as the form itself, so please read through them to get the proper syntax for implementation into your own projects.&lt;br /&gt;&lt;br /&gt;Enjoy!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4086249908856332456-9159300301156719646?l=mikekleiman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mikekleiman.blogspot.com/feeds/9159300301156719646/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4086249908856332456&amp;postID=9159300301156719646&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/9159300301156719646'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/9159300301156719646'/><link rel='alternate' type='text/html' href='http://mikekleiman.blogspot.com/2007/12/xhtml-compliant-javascript-form.html' title='XHTML Compliant JavaScript Form Validator'/><author><name>Mike Kleiman</name><uri>http://www.blogger.com/profile/04730089168344499371</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4086249908856332456.post-2030427165620517444</id><published>2007-12-17T10:05:00.000-05:00</published><updated>2007-12-17T12:28:51.379-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Images'/><category scheme='http://www.blogger.com/atom/ns#' term='Email'/><category scheme='http://www.blogger.com/atom/ns#' term='File Size'/><title type='text'>My top 4 tips for image usage in email</title><content type='html'>Bigger isn’t better when it comes to email. Heavy graphics contribute to slow load times, increased bandwidth costs and a less than satisfying user experience. That’s why optimizing the images you place in your marketing email is an important piece of the creative puzzle.&lt;br /&gt;&lt;br /&gt;With that being said, here are my top 4 tips for image usage in HTML email:&lt;br /&gt;&lt;br /&gt;&lt;b&gt;File format&lt;/b&gt;&lt;br /&gt;JPG’s are best for larger graphics that consist primarily of images, such as a masthead photograph. GIF’s are perfect for smaller items which contain less colour complexity and/or text – graphical buttons, for example.&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Check out your template before you cut your images and figure out which file formats are better based on the rule above.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Avoid saving anything in a format other than JPG or GIF. Though you might be tempted to save an image as a PNG for the sake of maintaining opacity percentages – it’s not a good idea. They work, but your file size will be huge. Instead, try to find a workaround or a different way to lay out the design.&lt;/li&gt;&lt;br /&gt;&lt;/ol&gt;&lt;b&gt;Reduce the size of large images even further&lt;/b&gt;&lt;br /&gt;Split up graphical items when possible. Say, for example, you have a masthead that is 600px wide. 400px of that masthead is just an image, and 200px is a flat colour background with stylized text on top of it. If you save the entire 600px image as one JPG you will not only end up with a larger file size than needed, but your stylized text will appear degraded and blurry.&lt;br /&gt;&lt;br /&gt;On the other hand, saving the entire masthead as a GIF will increase file size exponentially and will only allow the image portion to display 256 colours max.&lt;br /&gt;&lt;br /&gt;Your best bet would be to cut the image into two sections; GIF for the portion with text and JPG for the rest. This will significantly reduce the bandwidth required – and it bears remembering that a bandwith drop of just 2-3kb can equal a considerable savings when you’re sending to a list of 100,000+ subscribers.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Saving images in Adobe Photoshop&lt;/b&gt;&lt;br /&gt;To start with, you’re better off using Adobe Image Ready when it’s time to save your final images for production. In either Photoshop or Image Ready, be sure to use the "save for web" feature. The tweaks available in that save format allow you to really cut down the file size and play with quality/colour palettes in much finer detail than just your average Save As dialogue box. If you work with other graphic programs, you can explore their options for prepping images for web.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Quality vs. Quantity in a JPG and a GIF&lt;/b&gt;&lt;br /&gt;Feel free to run down the quality of JPGs that are nothing more than an image (eg, no text overlay). You might think you need the best possible quality on that beautiful image but, in fact, the difference between saving a JPG at 80% quality in Photoshop as opposed to 40% is usually negligible. Tinker with it to see how low you can bring down the percentage before the image becomes distorted. A jump from 80 to 40 may only have minimal visual impact but can save you a lot in the file size department.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;My number one piece of advice for when you sit down to turn a beautiful design into a functioning, low file size email?&lt;/b&gt;&lt;br /&gt;Take a step back and figure out what needs to be an image and what doesn’t. Often using simple HTML and inline CSS can replace the need for an image. Consider this... You have a header that consists of nothing more than a 300px x 200px brown background with white, Arial text on top.&lt;br /&gt;&lt;br /&gt;You have two options:&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Save the header as an image. Following rule number one, you’ll be saving it as a GIF to ensure text quality. This will cost you 1-3kb in file size. It will also mean that, with images turned off, that header will be unreadable by default in most of the email/webmail clients on the market today. Ouch.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Use HTML and inline CSS to ‘recreate’ the brown background and white text on top. You may not get Anti-aliasing, or an exact font match, but you will save on file size and get your message across even with images-off and, in most cases, that’s more important.&lt;/li&gt;&lt;br /&gt;&lt;/ol&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4086249908856332456-2030427165620517444?l=mikekleiman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mikekleiman.blogspot.com/feeds/2030427165620517444/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4086249908856332456&amp;postID=2030427165620517444&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/2030427165620517444'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/2030427165620517444'/><link rel='alternate' type='text/html' href='http://mikekleiman.blogspot.com/2007/12/bigger-isnt-better-when-it-comes-to.html' title='My top 4 tips for image usage in email'/><author><name>Mike Kleiman</name><uri>http://www.blogger.com/profile/04730089168344499371</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4086249908856332456.post-6005790439843744790</id><published>2007-12-14T13:58:00.000-05:00</published><updated>2007-12-14T19:34:47.985-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Email'/><title type='text'>Welcome!</title><content type='html'>Hello one and all to my new blog! The purpose of this bad boy is to keep tabs/track of the latest and greatest in the world of coding for email.... with a little bit of CSS and XHTML throw in for good measure.&lt;br /&gt;&lt;br /&gt;You might be thinking, coding for email, how hard can that be? A div here, a float there, maybe a table in-between? Well, with little to no background it's guaranteed to be a slippery slope of high spam scores, codes that look nothing like the creative and emails that degrade into anything but a reinforced brand awareness message.&lt;br /&gt;&lt;br /&gt;I've been working with email now for the past 2+ years and it requires a coder to not only stay on top of the latest developments with email clients (ie: new Gmail, Outlook 2007) but also find new an innovative ways to ensure that no matter who is getting your email, they're seeing exactly what you intended them to.&lt;br /&gt;&lt;br /&gt;With that in mind, I'll be using this space to share with you all the cool tips and tricks that I've developed in my toolkit, as well as some handy suggestions for best practice coding... PLUS on top of all this, I do occasionally enjoy coding a website or two and that has given me the ability to become a bit of a CSS/XHTML fan. So if I discover any handy tips, you'll be sure to see them here as well.&lt;br /&gt;&lt;br /&gt;Check back soon for my first "real" entry, my top tips on how you can save images to maximize impact and minimize bandwidth.&lt;br /&gt;&lt;br /&gt;Cheers&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4086249908856332456-6005790439843744790?l=mikekleiman.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://mikekleiman.blogspot.com/feeds/6005790439843744790/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4086249908856332456&amp;postID=6005790439843744790&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/6005790439843744790'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4086249908856332456/posts/default/6005790439843744790'/><link rel='alternate' type='text/html' href='http://mikekleiman.blogspot.com/2007/12/welcome.html' title='Welcome!'/><author><name>Mike Kleiman</name><uri>http://www.blogger.com/profile/04730089168344499371</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>
