1
1
1
1
1
1
1
1
1
1
1
1
4
4
4
4
8
6
6
12

The default grid system provided in Bootstrap utilizes 12 columns that render out at widths of 724px, 940px (default without responsive CSS included), and 1170px. Below 767px viewports, the columns become fluid and stack vertically.

<div class="row">
    <div class="span4">...</div>
    <div class="span8">...</div>
</div>

As shown here, a basic layout can be created with two "columns", each spanning a number of the 12 foundational columns we defined as part of our grid system.


Offsetting columns

4
4 offset 4
3 offset 3
3 offset 3
8 offset 4
<div class="row">
    <div class="span4">...</div>
    <div class="span4 offset4">...</div>
</div>

Nesting columns

With the static (non-fluid) grid system in Bootstrap, nesting is easy. To nest your content, just add a new .row and set of .span* columns within an existing .span* column.

Example

p>Nested rows should include a set of columns that add up to the number of columns of it's parent. For example, two nested .span3 columns should be placed within a .span6.

Level 1 of column
Level 2
Level 2
<div class="row">
     <div class="span6">
        Level 1 column
        <div class="row">
            <div class="span3">Level 2</div>
            <div class="span3">Level 2</div>
        </div>
    </div>
</div>

Fluid columns

1
1
1
1
1
1
1
1
1
1
1
1
4
4
4
4
8
6
6
12

Percents, not pixels

The fluid grid system uses percents for column widths instead of fixed pixels. It also has the same responsive variations as our fixed grid system, ensuring proper proportions for key screen resolutions and devices.

Fluid rows

Make any row fluid simply by changing .row to .row-fluid. The columns stay the exact same, making it super straightforward to flip between fixed and fluid layouts.

Markup

<div class="row-fluid">
    <div class="span4">...</div>
    <div class="span8">...</div>
</div>

Fluid nesting

Nesting with fluid grids is a bit different: the number of nested columns doesn't need to match the parent. Instead, your columns are reset at each level because each row takes up 100% of the parent column.

Fluid 12
Fluid 6
Fluid 6
<div class="row-fluid">
    <div class="span12">
        Level 1 of column
        <div class="row-fluid">
            <div class="span6">Level 2</div>
            <div class="span6">Level 2</div>
        </div>
    </div>
</div>

Fixed layout

The default and simple 940px-wide, centered layout for just about any website or page provided by a single <div class="container">.

<body>
    <div class="container">
        ...
    </div>
</body>

Fluid layout

<div class="container-fluid"> gives flexible page structure, min- and max-widths, and a left-hand sidebar. It's great for apps and docs.

<div class="container-fluid">
    <div class="row-fluid">
        <div class="span2">
            <!--Sidebar content-->
        </div>
        <div class="span10">
            <!--Body content-->
        </div>
    </div>
</div>

What they do

Media queries allow for custom CSS based on a number of conditions—ratios, widths, display type, etc—but usually focuses around min-width and max-width.

  • Modify the width of column in our grid
  • Stack elements instead of float wherever necessary
  • Resize headings and text to be more appropriate for devices

Use media queries responsibly and only as a start to your mobile audiences. For larger projects, do consider dedicated code bases and not layers of media queries.

Supported devices

Bootstrap supports a handful of media queries in a single file to help make your projects more appropriate on different devices and screen resolutions. Here's what's included:

Label Layout width Column width Gutter width
Smartphones 480px and below Fluid columns, no fixed widths
Smartphones to tablets 767px and below Fluid columns, no fixed widths
Portrait tablets 768px and above 42px 20px
Default 980px and up 60px 20px
Large display 1200px and up 70px 30px

Requires meta tag

To ensure devices display responsive pages properly, include the viewport meta tag.

<meta name="viewport" content="width=device-width, initial-scale=1.0">

Using the media queries

Bootstrap doesn't automatically include these media queries, but understanding and adding them is very easy and requires minimal setup. You have a few options for including the responsive features of Bootstrap:

  1. Use the compiled responsive version, bootstrap-responsive.css
  2. Add @import "responsive.less" and recompile Bootstrap
  3. Modify and recompile responsive.less as a separate file

Why not just include it? Truth be told, not everything needs to be responsive. Instead of encouraging developers to remove this feature, we figure it best to enable it.

  /* Landscape phones and down */
  @media (max-width: 480px) { ... }
  /* Landscape phone to portrait tablet */
  @media (max-width: 767px) { ... }
  /* Portrait tablet to landscape and desktop */
  @media (min-width: 768px) and (max-width: 979px) { ... }
  /* Large desktop */
  @media (min-width: 1200px) { ... }

Responsive utility classes

What are they

For faster mobile-friendly development, use these basic utility classes for showing and hiding content by device.

When to use

Use on a limited basis and avoid creating entirely different versions of the same site. Instead, use them to complement each device's presentation.

For example, you might show a <select> element for nav on mobile layouts, but not on tablets or desktops.

Support classes

Shown here is a table of the classes we support and their effect on a given media query layout (labeled by device). They can be found in responsive.less.

Class Phones 480px and below Tablets 767px and below Desktops 768px and above
.visible-phone Visible
.visible-tablet Visible
.visible-desktop Visible
.hidden-phone Visible Visible
.hidden-tablet Visible Visible
.hidden-desktop Visible Visible
互动营销型网站建设信息安全等级保护工作会议公安部 信息安全通报中心网站字体搜索营销营销与数字营销的区别深圳信息安全企业,-1网站打开速度优化信息安全测试方法营销型页面无尽虚空,暗域缘起,幻境连绵,魂牵梦萦。如泡现盈破,似影隐现。通篇尽是浮想联翩,异想天开之事物,是略显温和的怪谈。内蕴玄机,有缘人或可勘破。一场意外,李信穿越异世界,成为了大乾王朝三皇子。 看着千里冰封、万里雪飘的封地,还没来得及感慨,就遭遇到了草原马匪袭击。 幸运的是,李信拥有远超这个时代的科技。 种种田,搞搞工业,建设封地,抵御草原马匪…… 直到有一天,等他回过神来才发现,当初贫瘠寒冷的封地,已经成为了一座钢铁雄城…… “什么?水泥、煤球炉、蒸馏酒……还有这些,都是信王殿下的发明?” “什么?信王殿下的封地,高楼林立、直入天际,那是人类的奇迹啊!” “什么?信王殿下的大军,荡平草原了?那简直是钢铁洪流啊!” “什么?信王大军入关,逼近京城了……” …… 世人在一次又一次震惊中,看着信王李信以封地为起点,逐步打造出一个钢铁皇朝! 【穿越+倒爷+搞笑+轻松+日常+玩梗+时事+胡亥+项羽+美女】 好消息!好消息! 江南皮革厂倒闭了,老板黄贺没有带着小姨子跑路,获得秦朝和现实来回穿越的能力。 作为商人的黄贺,充分发扬老秦人吃苦耐劳的精神,没有996,没有007,只要干不死,就往死里干。 秦朝的无限资源,现代的工业技术,碰撞出激烈的火花。 且看一个现代人,如何在秦朝和现实一步一步的爬到最高,打到赵高,带领老秦人冲出欧亚,走向世界。 一觉醒来,朱高熙来到朱元璋面前:“皇爷爷,我有六策,可保大明万世!” …… 沈灰穿越到可以觉醒世界本源,创造属于自己世界,成为造物主的星球。 有人打造修真文明,有人打造科技文明…… 而沈灰觉醒的却是死亡世界,里面充满了死亡负能量。 一切活物都无法进行创造,被认为是毫无用处的废物世界。 不过作为知晓各种鬼怪,都市怪谈的沈灰,直接打造了一个不要生命的怪谈世界。 贞子,猪头屠夫,富江,警笛头,寂静岭…… 一个个诡异生物或者诡异区域被沈灰创造出来。 不知不觉中,沈灰打造的诡异怪谈世界,让全世界都为之感到恐惧!每天一个,别嫌多、也别嫌少一个平凡少年步入除魔降妖的道路,一步步踏上轩盏龙炎的驱灵人。 2116年,人类的科学上了一个大台阶。所有的人都在未来的世界中过着无比幸福且快乐的生活,他们永远年轻,不会衰老,没有疾病,他们拥有机器仆人,磁悬浮飞行器,全息情人等一切高科技产品,幸福似乎成为了这个世界的唯一准则。但是在这个世界中的人们永远都不记得昨天发生了什么。   一名男子的跳楼自杀打破了这个幸福的美好世界的面纱,徐飞警官在调查男子自杀这个案件的时候却意外的在男子的遗书中发现了这个世界的真相,然而他还不知道,有一个更大的阴谋真在等待这他........最强兵王归来,竟发现家人被逼迁,一怒之下,风云骤变,血流成河。他本想闲云野鹤悠闲度日,却陪她纵横商界叱诧风云,为她打下一片江山。宇宙星河   无尽虚空   凌驾于天道之上   掌管无尽宇宙   不被任何人打败   她就是墨星玄
信息安全项目计划 湛江做网站 营销网络学校 网站建设吗 深圳网站建设设计 网络安全框架怎么写 湖南微信网站营销 2016网络安全重大事件 网站建设吗 网站建设 cms 下载 o2o网站建设代理商 信息安全认证启动会 公司信息安全系统包括 一个完整的信息安全保障体系包括 安徽省 信息安全 信息安全测试方法 鄂州做网站 四川大学网络安全硕士 鄂州做网站 互联网营销网站有哪些 自己怎样制作公司网站 网络营销的网站分类 下载免费网站模板下载安装 自己怎样制作公司网站 2017年网络安全大会 免费设计网站 网络与信息安全教程 营销网络学校 南京网站建设 网站推广教程 上海营销型网站 如何攻破网络安全审计监控系统 网络安全 数据分析 湖南网站优化 国美网络营销策略 国外的app设计网站 领域网站建设 国家网络安全标准化 岳阳网站建设 珠海集团网站建设外包 石家庄网站制作微信营销成功的案例 如何做好微信群营销方案 软文营销的推广技巧 南通动态网站建设 安徽省 信息安全 新媒体营销有哪些 新媒体营销有哪些 原型图网站 信息网络安全建设方案 新田网络营销 许可email营销的实施 对信息安全管理威胁最大的是 网站优化课程 网络和信息安全专业介绍 欧盟 网络安全审查 网站建设 cms 下载 学网络营销的好处 教育式营销 网络安全产品分类 机房信息安全评估报告 福州口碑营销 网络营销可以吗 网络营销 工作室 国家网络安全管理员的认证 信息安全培训机构课程 云南网络营销 信息安全项目计划 营销网络学校 个人网站在那建设 病毒营销的发展趋势 信息安全铁人三 电商网站报价 airbnb营销模式 佛山网站设计讯息 信息安全 it风险评估 深圳信息安全企业,-1 湖北信息安全网络技术 互动营销型网站建设 互动营销型网站建设 信息安全培训机构课程 网络与信息安全教程 airbnb营销模式 新闻营销案例 兰州网站制作 昆明网站开发多少钱 大数据技术与网络安全 小红书营销推广 互联网营销网站有哪些 上海企业网站 获取网站的路径 网络营销平台建设方案 腾讯的网络营销 it信息安全 大网站成本 绵阳的网站制作公司 网络信息安全服务包括,-1 信息安全等级保护工作会议 金融网站建设 网络广告营销模式案例 呼和浩特做网站的公司有哪些 雅虎网络安全 信息安全认证启动会 2010年网络营销关键词两会 网络安全 郑州网站建设最独特 网站建设 cms 下载 网络安全框架怎么写 呼和浩特做网站的公司有哪些 信息安全类产品 网站免费认证第四届首都网络安全日 教你做网站 教你做网站 小红书营销推广 教育式营销 互联网营销推广 公安部 信息安全通报中心 b北京网站建设 国家网络安全标准化 网络安全法与网信工作 网络营销在我国的发展现状 网站行销 微活动营销案例 如何攻破网络安全审计监控系统 网站建设 长春 信息安全项目计划 信息安全认证启动会 日照网站制作外贸网站的建设 廊坊设计网站公司 一个完整的信息安全保障体系包括 整合营销运营 网络广告营销模式案例 信息安全测试方法 网络世界 网络安全 餐饮互联网营销 案例 国内欣赏电商设计的网站 下载免费网站模板下载安装 领域网站建设 关键基础信息安全评估 公司信息安全ppt idc网络安全市场分析报告 win7网络安全模式上qq 南通动态网站建设 企业网络联合营销案例 信息安全 it风险评估 互联网效果营销服务商 网络信息安全周启动,-1