一.html5shiv.js和respond.min.js
html5shiv:解决ie9以下浏览器对html5新增标签的不识别,并导致CSS不起作用的问题。
respond.min:让不支持css3 Media Query的浏览器包括IE6-IE8等其他浏览器支持查询。
由于IE6/IE7/IE8还有很大一部分用户,为了让网站浏览者都能正常的访问HTML5网站,故这两种方案还是需要的。
<!-- [if lt IE 9] -->
<!-- <script src="../js/html5shiv.min.js"></script>
<script src="../js/respond.js"></script> -->
<!-- [endif] -->
原文地址http://www.cnblogs.com/yangjie-space/p/4816279.html
2、加入meta标签
确定显示此网页的IE版本
<meta http-equiv="X-UA-Compatible" content="IE=edge,Chrome=1" />
<meta http-equiv="X-UA-Compatible" content="IE=9" />
3、添加1.X版本的Jquery库
<script src="js/bootstrap/jquery-1.12.0.min.js"></script>
代码总结如下:
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="IE=edge,Chrome=1" />
<meta name="author" content="zhy" />
<title>ie8</title>
<link rel="stylesheet" href="css/bootstrap/bootstrap.min.css" rel="external nofollow" >
<!--[if lte IE 9]>
<script src=js/bootstrap/respond.min.js"></script>
<script src=js/bootstrap/html5shiv.min.js"></script>
<![endif]-->
<script src="js/bootstrap/jquery-1.12.0.min.js"></script>
<script src="js/bootstrap/bootstrap.min.js"></script>
</head>
<body>
</body>
</html>
原文地址 http://www.jb51.net/article/83366.htm