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
三天了信用卡会通过吗广发信用卡免费换卡办法信用卡拖欠300建行信用卡积分办理财白宜宾工行信用卡看电影广发信用卡二次评估交通银行信用卡热线信用卡拖欠300建行信用卡申请推荐码信用卡套现什麽处罚龙卡云南热购信用卡金卡额度三天了信用卡会通过吗交行信用卡编号查不到微信女要求还信用卡信用卡拖欠300信用卡套现什麽处罚无免息期的属于信用卡还是贷款卡为啥每次办理信用卡不通过为啥每次办理信用卡不通过全款车办信用卡如何让信用卡磁条失效 芯片卡为啥每次办理信用卡不通过建行信用卡申请推荐码我在网上申请信用卡没事吧宜宾工行信用卡看电影信用卡欠款20万还不上怎么办建行信用卡积分办理财白我在网上申请信用卡没事吧建行信用卡可以贷款交行信用卡编号查不到楚林重生穿越到一个未知的修仙世界。 武功尽失、曾被称为“奇才少年”的他跌落神坛。 正当楚林痛饮美酒,卧床难安时,他居然又跑回现实了。 从此获得:驾驭现世与修仙世界! 某天公司举办Cosplay展览会,楚林意外遇见一名古装女子。 她窈窕妩媚,柔桡轻曼,冰肌莹彻,两眼流苏像极了制作游戏里的人物。 “凛秋雪,这个家伙居然也跑到现实了!” 楚林不敢置信地抓住她的皓腕,只见凛秋雪铁青着脸。 “流氓!” 少年李杉逃出生天后,进入小城。正逢下岗改制,他一脚踏进这个旋涡。 这是一个变革的时代,一个机遇丛生又步步惊心的时代。 他在阴谋迫害中自保,在明争暗斗中生存。 在达官显贵的权谋中游走,在血与火的锤炼中成长。 在各方势力的角逐中壮大。他先天少一魂一魄,五行不全,补救之法是他需要补足阴阳,吸取五行。一个天罚之人——林气象! 为了活命他放弃修仙的机会辗转都市,行走于霓虹之下,见识人间百态,红尘炼心。寻找四十九个女朋友,累如死狗,迫于各种压力斗黑帮,挑武林。最后发现自己之所以有这样的命运,居然是因为被人安排了一道,抢了自己的一魂一魄和五行之力,这一切只是因为自己有个帝王命。我的命运简单、荒谬,我家境贫寒,却并未因此自卑,这点倒值得研究。我不甘平凡,通过自己的努力最终改变了命运。 我一直希望能做块玉,也以为自己就是块玉,其实不过是自我催眠,我到底是个摆脱不了“铜臭味儿”的俗人。本作品衔接蓝猫龙骑团第三部尘寰外,碧海中,桃花之间桃花岛。秋风起,海波兴,几度潮来听玉箫。且看东邪黄药师传人,如何纵横都市。满天神佛朝我跪拜,天下美女唯我独揽!已完本,放心阅读。李梦,一个普普通通上班族,每天过着朝九晚五的社畜生活。 可是,突然有一天,当他打开卧室门的时候,一切都变了…………… 李梦:别人穿越有金手指,我穿越差点饿死。 朱棣:此人奇装异服,想来一定是蒙古鞑子的哨探。来人,将此人拿下! 李梦:猪迪(中式英语)我谢谢你八辈祖宗………… 从此,朱棣身边就多了个狗头军师 现代都市和平生活并未持续多久。当平行的世界被人们挖掘到信息,位面重叠,世界重启。这里变成了修行者的世界。无尽的尸海,广阔的荒漠,万族林立,百家争霸,无情的杀戮将一切虚幻斩断,而何处才是人类栖息之地?一卷封神榜,一座封神台,为异界带来一个异数,也是一个变数,掀起波澜壮阔的江湖烽烟。五百年必有王者兴,三千载则当圣人现,一万年沧海桑田,阴川之下,造化之工,天照点将,揭开三千年后封神大战的帷幕。龙啸九天,正心泯仇;凤鸣寰宇,修身弘愿。封神榜起,封神台终,登天梯下,上演着血与火的恩怨情仇…… 贫道纯属虚构,如有雷同,你能咋滴?拔刀吧——人生赢家!人的一生就像一幅画卷 而朋友则在画卷上留下浓墨重彩的一笔 还记得那些年陪你一起闯荡的朋友嘛
魔法史诗 猎灵士 自由勇者的异世界冒险 揭开一角的世界 仙帝争锋 规则碎片 山道弯弯下 繁华的守护者 重生之我的侄儿是天选? 故事分享集 奇异国 返祖我的先祖是曹孟德 修罗宁神纪 丹经启始 虚拟世界游戏之玩家降临 澧水悠悠梦 大宋狂徒 我在异世界当农夫 拥有超能力后的我 拿脚想的剧本都比戴卡强 如何让信用卡磁条失效 芯片卡 微信女要求还信用卡 交通信用卡好下卡吗 建行信用卡积分办理财白 如何让信用卡磁条失效 芯片卡 购物办什么信用卡 交通银行信用卡热线 信用卡卡贷款网上诈骗 广发信用卡免费换卡办法 宜人贷信用卡验证不了 在哪买信用卡用户名单 在哪买信用卡用户名单 信用卡办理 合影 龙卡云南热购信用卡金卡额度 广发信用卡二次评估 宜宾工行信用卡看电影 在哪买信用卡用户名单 信用卡欠款20万还不上怎么办 如何让信用卡磁条失效 芯片卡 三天了信用卡会通过吗 信用卡卡贷款网上诈骗 信用卡拖欠300 广发信用卡免费换卡办法 微信女要求还信用卡 信用卡套现什麽处罚 建行信用卡消费几百块影响房贷吗 信用卡欠款20万还不上怎么办 广发信用卡免费换卡办法 如何让信用卡磁条失效 芯片卡 信用卡欠款20万还不上怎么办 宜宾工行信用卡看电影 信用卡卡贷款网上诈骗 工行 信用卡 风险 三天了信用卡会通过吗 我在网上申请信用卡没事吧 宜宾工行信用卡看电影 工行 信用卡 风险 无免息期的属于信用卡还是贷款卡 建行信用卡消费几百块影响房贷吗 工行 信用卡 风险 宜宾工行信用卡看电影 广发信用卡余额 全款车办信用卡 信用卡没有通过审核 微信女要求还信用卡 信用卡卡贷款网上诈骗 信用卡没有通过审核 建行信用卡积分办理财白 建行信用卡可以贷款 交通银行信用卡热线 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 网游之星觉逆世 谁可逆天 海贼王:开局拜卡普为师 我的超级丧尸女友 苍天龙猫 亚星管理平台 澳门葡京官网 葡京官网 亚星管理平台 万利官网 交通信用卡好下卡吗 交行信用卡编号查不到 我在网上申请信用卡没事吧 交通信用卡好下卡吗 在哪买信用卡用户名单 信用卡办理 合影 信用卡没有通过审核 微信女要求还信用卡 建设银行用车办信用卡 微信女要求还信用卡 三天了信用卡会通过吗 龙卡云南热购信用卡金卡额度 信用卡欠款20万还不上怎么办 交行信用卡编号查不到 信用卡办理 合影 工行 信用卡 风险 建行信用卡消费几百块影响房贷吗 信用卡办理 合影 龙卡云南热购信用卡金卡额度 我在网上申请信用卡没事吧 全款车办信用卡 微信女要求还信用卡 广发信用卡二次评估 建行信用卡消费几百块影响房贷吗 信用卡拖欠300 建行信用卡申请推荐码 交行信用卡编号查不到 建设银行用车办信用卡 建行信用卡积分办理财白 三天了信用卡会通过吗