最新版本的 Safari、Chrome、Firefox 以及 Opera 支持某些 HTML5 特性。Internet Explorer 9 將支持某些 HTML5 特性。

IE9 以下版本瀏覽器兼容HTML5的方法,使用百度靜態(tài)資源的html5shiv包:
<!--[if lt IE9]-->
<script src="http://apps.bdimg.com/libs/html5shiv/3.7/html5shiv.min.js"></script>
<!--[endif]-->
載入后,初始化新標簽的CSS:
/*html5*/ article,aside,dialog,footer,header,section,footer,nav,figure,menu{display:block}
html5shiv.js 引用代碼必須放在<head>元素中,因為 IE 瀏覽器在解析 HTML5 新元素時需要先加載該文件。