Skip to content

Latest commit

 

History

History
23 lines (17 loc) · 1.23 KB

html5-enabling-script.md

File metadata and controls

23 lines (17 loc) · 1.23 KB
title date published tags modified
HTML5 enabling script
2009-01-07 13:49:54
true
code
html
html5
javascript
2014-09-03 16:15:12

HTML5 enabling script

Since HTML5 is getting more attention by way of marking up our new pages, and the only way to get IE to acknowledge the new elements, such as <article>, is to use the HTML5 shiv, I've quickly put together a mini script that enables all the new elements.

Usage & Download

Download html5shiv.js and must be inserted in the head element (this is because IE needs to know about the element before it comes to render them - so it can't sit in the footer of the page, i.e. below the elements in question).

I've updated this post to link to Alexander Farkas's version of the shiv - it's the very latest and my simple one line script. The one I originally released was (I thought) beautifully small, but didn't support print styles nor dynamic injection of HTML5 elements. Good thing there are smarter folk than I!