一开始,IE是代表了浏览器的进步。现在的IE仍落后于基于WebKit的浏览器和火狐。我们也还需要适应较早版本的IE浏览器。以下将让您的网站迅速,几乎奇迹般地工作在IE下。
htmlshiv.js
使用方法:
<!--[if lt IE 9]> <script src="dist/html5shiv.js"></script> <![endif]-->
selectivizr.js
使用方法:
<!--[if lte IE 8]> <script src="js/libs/selectivizr.js"></script> <![endif]-->
html条件注释
最丑的条件注释系列:
<!DOCTYPE html> <!--[if lt IE 7 ]> <html class="ie6" lang="en"> <![endif]--> <!--[if IE 7 ]> <html class="ie7" lang="en"> <![endif]--> <!--[if IE 8 ]> <html class="ie8" lang="en"> <![endif]--> <!--[if IE 9 ]> <html class="ie9" lang="en"> <![endif]--> <!--[if (gt IE 9)|!(IE)]><!--> <html lang="en"> <!--<![endif]-->