bootstrap兼容IE
这种响应式的布局正是通过CSS3的媒体查询(Media Query)功能实现的,根据不同的分辨率来匹配不同的样式。IE8浏览器并不支持这一优秀的Css3特性,Bootstrap在开发文档中写了如何使用进行兼容IE8,如果想兼容IE6,IE7,可以搜索bsie (bootstrap2)。
http://v2.bootcss.com
1,注意,使用bootstrap最好使用2.0以下的jquery;
2,ie8以下不支持placeholder
<script type="text/javascript" src="js/bootstrap/jquery.placeholder.js"></script>
<script type="text/javascript">
$(function () {
$('input, textarea').placeholder();
});
</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">
<!--[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>
IE判断IE版本的语句:
<!--[if lte IE 6]>
<![endif]-->
IE6及其以下版本可见 <!--[if lte IE 7]>
<![endif]-->
IE7及其以下版本可见 <!--[if IE 6]>
<![endif]-->
只有IE6版本可见 <![if !IE]>
<![endif]>
除了IE以外的版本 <!--[if lt IE 8]>
<![endif]-->
IE8以下的版本可见 <!--[if gte IE 7]>
<![endif]-->
IE7及大于IE7的版本可见
lte:就是Less than or equal to的简写,也就是小于或等于的意思。
lt : 就是Less than的简写,也就是小于的意思。
gte: 就是Greater than or equal to的简写,也就是大于或等于的意思。
gt : 就是Greater than的简写,也就是大于的意思。
! : 就是不等于的意思,跟javascript里的不等于判断符相同
bootstrap兼容IE的更多相关文章
- 解决easyui和bootstrap兼容问题
在使用bootstrap和easyui的时候,发现很多有冲突的地方,包括datagrid控件和combo等,以下进行的问题修正,保证easyui正常显示 /*bootstrap兼容问题和easyui的 ...
- bootstrap 兼容 IE8
在 html 中引用 <!-- bootstrap 兼容 IE8 --> <script src="../../jsapi/js/html5shiv.min.js" ...
- Bootstrap兼容
转:http://blog.csdn.net/chenhongwu666/article/details/41513901 如有雷同,不胜荣幸,若转载,请注明让IE6 IE7 IE8 IE9 IE10 ...
- bootstrap兼容IE8的一些注意
准备 bootstrap 3.3.5 jQuery 1.12.0 注意 支持html5 需要引入html5.js 支持placeholder 需要引入placeholder.js ie8 不支持 fo ...
- Bootstrap兼容IE8
使用BootStrap3.x写的公司一个响应式项目在IE下面错误百出,经过一番折腾.全部解决了IE8下的兼容问题. 这里汇总一下,希望对大家有所帮助. 1. Bootstrap UI整体在IE8下变窄 ...
- bootstrap兼容IE8 解决办法
bootstrap有使用CSS3,所以ie9以下浏览器不会很顺畅.IE9以下的兼容性不是很好.IE本身就是怪胎,就搞一些和外界标准不一致.搞得web开发考虑这考虑那的兼容性,蛋疼! 基本上css3的没 ...
- bootstrap 兼容哪些浏览器
Bootstrap的目标是在最新的桌面和移动浏览器上有最佳的表现,也就是说,在较老旧的浏览器上可能会导致某些组件表现出的样式有些不同,但是功能是完整的.bootstrap3支持的浏览器: Chrome ...
- bootstrap 兼容IE8设置
<!--[if lt IE 9]> <script src="//cdn.bootcss.com/html5shiv/3.7.2/html5shiv.min.js" ...
- Bootstrap兼容处理
接将一下代码引用到页面 </body> 之前 <script src="//cdn.bootcss.com/jquery/1.11.3/jquery.min.js" ...
随机推荐
- NOIP2010 引水入城
4引水入城 题目描述 在一个遥远的国度,一侧是风景秀美的湖泊,另一侧则是漫无边际的沙漠.该国的行政区划十分特殊,刚好构成一个N 行M 列的矩形,如上图所示,其中每个格子都代表一座城市,每座城市都有一个 ...
- zoj 1670 Jewels from Heaven
题意:三个人,在给定正方形内,求第一个人拿到珠宝的概率.珠宝随机出现在正方形内. 思路:中垂线+半平面相交. #include<cstdio> #include<cstring> ...
- Hdu 5289-Assignment 贪心,ST表
题目: http://acm.hdu.edu.cn/showproblem.php?pid=5289 Assignment Time Limit: 4000/2000 MS (Java/Others) ...
- leetcode—word ladder II
1.题目描述 Given two words (start and end), and a dictionary, find all shortest transformation sequence( ...
- [学姿势]使用AngularJS+CodeIgniter框架经验谈
这篇文章作为总结总结7月份参与项目时遇到的新东西和问题,包括这两个框架(CodeIgniter.AngularJS)以及两个功能实现.有前端调试显示动态认证,也有用php实现功能模块. 1.添加设备 ...
- 10分钟制作自己的手机QQ
1.注册个bmob.cn的账号:什么是bmob?bmob就是一个提供了基本后台服务器数据库操作的一个平台,你可以不用担心后台操作,使用起来很方便,降低了开发的门槛,提高了开发效率. 2.创建应用: 这 ...
- hdoj 3371 Connect the Cities
Connect the Cities Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Other ...
- 用 C# 做人脸检测(EmguCV)
用 C# 做人脸检测(EmguCV) 原发:bbs.csdn.net 作者:野比 (conmajia@gmail.com) 时间:May 2012 下载源码 准备工作 下载 EmguCV 傻瓜安装 ...
- IDF实验室-简单编程-字符统计 writeup
题目地址:http://ctf.idf.cn/index.php?g=game&m=article&a=index&id=37 网站:http://ctf.idf.cn/gam ...
- IPAD之分割视图 SplitViewController
转载自:http://www.w3cschool.cc/ios/att-ios-ui-splitview-htm.html 1 分割视图的使用 分割视图是 iPad 的特定视图控制器用于管理两个视图控 ...