Bootstrap基本框架
来源:互联网 发布:fedora linux镜像下载 编辑:程序博客网 时间:2024/06/06 01:09
基本框架
<!DOCTYPE html><html> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1"><!-- maximum-scale=1.0 与 user-scalable=no 一起使用。这样禁用缩放功能后,用户只能滚动屏幕,就能让您的网站看上去更像原生应用的感觉。--!> <!--<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"> --!> <title>Bootstrap 模板</title> <!-- 引入 Bootstrap --> <link href="http://cdn.static.runoob.com/libs/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet"> <!-- HTML5 Shim 和 Respond.js 用于让 IE8 支持 HTML5元素和媒体查询 --> <!-- 注意: 如果通过 file:// 引入 Respond.js 文件,则该文件无法起效果 --> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script> <script src="https://oss.maxcdn.com/libs/respond.js/1.3.0/respond.min.js"></script> <![endif]--> </head> <body> <h1>Hello, world!</h1> <!-- jQuery (Bootstrap 的 JavaScript 插件需要引入 jQuery) --> <script src="https://code.jquery.com/jquery.js"></script> <!-- 包括所有已编译的插件 --> <script src="js/bootstrap.min.js"></script> </body></html>
响应式图片
<img src="..." class="img-responsive" alt="响应式图像">
其中img-responsive的class属性为:
.img-responsive { display: inline-block; height: auto; max-width: 100%;}
display: inline-block元素表明:相对于它周围的内容以内联形式呈现,但与内联不同的是,这种情况下我们可以设置宽度和高度。
设置 height:auto,相关元素的高度取决于浏览器。
设置 max-width 为 100% 会重写任何通过 width 属性指定的宽度。这让图片对响应式布局的支持更友好。
阅读全文
0 0
- Bootstrap基本框架搭建
- Bootstrap基本框架
- bootstrap框架之基本CSS样式
- bootstrap前端框架的简单基本使用
- Bootstrap-css前端框架(二、基本样式)
- 用bootstrap实现导航栏的基本代码框架
- Bootstrap 框架
- BootStrap框架
- Bootstrap框架
- bootstrap框架
- Bootstrap框架
- Bootstrap框架
- bootstrap 框架
- bootstrap框架
- bootstrap 基本模板
- bootstrap 基本模版
- bootstrap基本html 模板
- Bootstrap:基本模板
- USACO-Section1.3 Mixing Milk
- 80,90后需要提前领悟的至高心法
- 算法导论程序40--贪心算法(活动选择问题)
- 教你快速实现Nexus刷机
- 《SQL反模式》总结
- Bootstrap基本框架
- 个人感悟 动态绑定与静态绑定
- scala多线程demo
- 数据的位运算
- swift 单例的实现
- oj 1067: 顺序排号
- Jmeter断言-响应断言
- [Leetcode] 161. One Edit Distance 解题报告
- iOS 后台播放音乐问题记录