CSS styles set default styles:
<style>
Article, aside, canvas, details, figcaption, figure,
Footer, Header, Hgroup, menu, nav, section, summary
{
Display:block;
}
</style>
JS in:
<!--[If Lt IE 9]>
<script type= "Text/javascript" >
var e= ("Abbr,article,aside,audio,canvas,datalist,details," +
"Figure,footer,header,hgroup,mark,menu,meter,nav,output," +
"Progress,section,time,video"). Split (', ');
For (Var i=0;i<e. length;i++) {
Document.createelement (E[i]);
}
</script>
<! [endif]-->
=========================================================
Another way is to use the framework of the method, with the conditional comment plus JS code implementation
The code is as follows:
<!--[If Lt IE 9]>
<script src= "Html5shiv.js" ></script>
<! [endif]-->
This code can be directly added to achieve compatibility issues, about the conditions of attention in the
is to determine whether the following browser is less than IE9, if it is to execute this JS code, if not, ignore it. As for the JS link directly open to see it, is also a large section of the code.
How to make the old browser compatible with HTML5 new tags