If you have been considering moving over to HTML 5, but have been concerned because Internet Explorer doesn’t support it, then you’re going to love this script. Now you don’t have to wait until Internet Explorer 9 comes out and gains acceptance to use a lot of the great new tags in HTML 5.
It’s Called HTML Shiv
Jonathan Neal created a simple script that tells Internet Explorer 8 and below (and Firefox 2 for that matter) to treat HTML 5 tags as real tags. So that you can style them and use them in your documents.
There is also a version called HTML Shim which does the same thing.
How to Use HTML Shiv
Simply add the following three lines to your HTML 5 document in the <head> above your style sheet.
<!--[if lt IE 9]>
If you don’t want to point to the Google Code site, you can download the script file (shift click the link) and store it on your local machine, but then you won’t have access to any changes that are made.
Once you’ve added those lines you can then style your HTML 5 tags like you would for the HTML 5 compliant browsers.
The script uses Internet Explorer conditional comments to only run for Internet Explorer versions under 9.