Sorry for the late reply on this one. It must have slipped through my inbox to do...
We do a lot of email templates for a company that do mass mailouts for clients.
Basically its a pain in the ass trying to comply with all the different mail clients, they are all different and some use old rendering engines and lots of other cruddy stuff. Gmail hates background images and outlook can cause a few dramas as well. But here are some important points to get you across the line for most things...
Because different applications & clients render html emails in different ways and using different rendering engines, there are a few things that we need to adhere to so that the email displays correctly everywhere.
1. Do not include the standard html,head,title & body tags. The email should start with a table declaration with the width of 100%. If you want to set background colours and background images...do them on this table by using the "style=" attribute.
2. If you are going to be doing background colours/images, then do it using the above technique but also add a <style> body { ... } </style> to the top of the document as well.
3. In-line CSS is the way to go. Rather than declaring classes at the top...include the CSS in the actual attribute. This is only for really old email clients. So it's not 100% required but we like to do it still.
4. Any images or links inside the template should be absolute urls. Do not use "../images/logo.png", instead use the full url.
5. No external declarations. CSS or Javascript cannot be declared externally.
6. Javascript is not allowed.
7. Embedding any objects is also not allowed (this includes flash videos or any other type of embed).
8. Try to use table layouts at all times.
That's pretty much it. Everything at the top is pretty strict except for point 3. As I mentioned, online very old email clients (eg: Outlook on Win98) require CSS inside attributes...but it's a good practice.
here is an example of one of our layouts for a nightclub...
realworldmedia.com.au/clients/brownalley/newsletter/
If anyone is interested I have a massive xl spreadsheet which details the ins and outs of compliancy across all major mail clients..
cheers,
Anthony S.