Search code examples
javascripthtmlemailnewsletterhtml5shiv

html5 formatted email and the html5shiv: are these viable in email newsletters?


Suppose a website provides the facility to compose and send monthly email newsletters to subscribers. The email content is essentially html.

What are the implications of migrating the content to html5? In particular, how would most non-compliant email viewers handle the html5shiv script, if either:

  1. the html5shiv is referenced as external javascript,
  2. the html5shiv is included as part of the multi-part mime email encoding, or
  3. the html5shiv is embedded directly within script elements?

Alternatively, should html5 not yet be used as an emailable format?


Solution

  • No, html5shiv is not viable in email. html5shiv is JavaScript. JavaScript is not viable in HTML formatted email.

    I'm not aware of any email client that allows JavaScript to execute (other than through (already patched) security holes).