Is Outlook friendly HTML different from a regular web page?

My web app needs to deliver content created with db via email. HTML should not include javascript, but _does should include images and CSS.

It is a safe bet that most users will view this in Outlook. Are there general rules for html targeting email and IE?

+2


source to share


5 answers


Outlook doesn't have a good track record of HTML emails - see Microsoft Ignore Web Standards in Outlook 2010 - enough is enough , for example.

But this is not the only email client with problems, in fact: generating an HTML email usually means doing some things differently from a web page ...

For example, you might want to take a look at this article: Making Your HTML Emails Look Great and Delivered . A few things he does:



  • use inline CSS
  • use tables and main layout

Well ... quite the opposite of what is said for web pages, isn't it?

And a tip: always check your email to as many clients as possible (both desktop and Outlook, Thunderbird, ... and websites like yahoo, hotmail, gmail, ...)!

+9


source


Quite right. It's almost impossible to use CSS layout techniques in HTML emails. So ... code like 1998.

  • Use tables. It's painful, but it's the only surefire way to get HTML emails to display correctly and consistently. Make sure you set cellpadding, cellspacing and border for each individual table. Nest them if needed. colspan and rowspan are your friends. Use shim.gifs in empty cells. If this is not good practice for regular web pages, you should probably use them in emails.
  • Don't create anything over 600 pixels.
  • Since webmail CSS services can be overwritten by CSS inside emails, they tend to disable it. Inline CSS is smart. Font tags are smarter.
  • Forget about doctypes, <html>

    , <body>

    or <head>

    .
  • Don't rely on background images - if you must use them, you have a background color backup.
  • Avoid spam probing. Don't talk about Viagra, porn, or fake watches. - this is most likely spam being filtered
  • Send a text alternative using the "Multipart / Alternative" MIME type.
  • Debugging is a bear. The test list we use in my business: Outlook 2003, Outlook 2007, Outlook Express (with XP), Thunderbird Mac and Windows, Eudora, Mail.app, Entourage, Gmail, Yahoo! Mail, AOL, AOL Webmail, and Hotmail. Webmail clients have been tested in both IE6 and the latest version of Firefox. It might be worth preparing a script to automatically send emails to test addresses across all testing services.


Good information about specific support on the campaign monitoring site . They also have more practical guidelines . And here's a list of email client uses .

+8


source


In Outlook 2007, it took a huge step back: http://www.sitepoint.com/blogs/2007/01/10/microsoft-breaks-html-email-rendering-in-outlook/

Instead of using IE for the rendering engine, it now uses Word. Only the most basic HTML is supported well or at all.

+2


source


0


source


Electronic user agents tend to deviate significantly from the standards for CSS and HTML. Some email agents, like Thunderbird, claim to have full CSS support in email, but as far as I know, the email user agent fully supports the HTML standard.

HTML is for the web, specifically for HTTP transmission. It contains header definitions, all bits that fall under the <head> </head> tags that are meant to work over HTTP transmission. HTML is a markup language that is a structured data document. Markup languages ​​are not presentation languages, but HTML's only point of use in email is for presentation. As a result, HTML doesn't work in email and is hardly available.

In HTTP, a user requests a resource from a server, and the server responds with that resource. The author of a document provided from the server is someone who can create documents on the server. A resource provided by HTTP has only one author.

In an email, a document can be written by many different anti-HTTP users. The document is not generated on the server. Because the document is not generated in server or well-known monolingual markup languages ​​and containment and CSS scoping issues. This means that HTML and CSS in email is completely incompatible with the notion of an email flow in which multiple people contribute to a document, because CSS doesn't understand that it should be limited to a single instance of a link.

Because of these incompatibilities, which were never meant to exist, and are not intended to be fixed, Microsoft is fully committed to supporting as few or as many HTML emails as possible. There is no standard solution to this problem, so there is no violation. The violation uses HTML in the email to begin with.

My advice is to wait until Markup is adopted. If we're all very lucky, one particular user agent vendor may announce the adoption of Mail Markup Language in the near future. As far as I know, Mail Markup Language is the only functional markup language specification to meet current email flow needs.

0


source







All Articles