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
尝试双飞 小说御宠至尊 虾小米 小说啊老公我要生了小说大三 玄夜 小说date a live小说下载跪侍 会所 小说小说 盗情啊老公我要生了小说剑修 小说小说 女 绰号超级饭店 79小说尝试双飞 小说百度书城免费阅读网 小说逆鳞 骑着蜗牛去旅行 小说啊老公我要生了小说小说 女 绰号军事小说 火力quanji 下载神音系小说神音系小说脸皮 小说下载默爱成殇 三月有桃花 小说神音系小说剑修 小说异界 搞笑小说date a live小说下载藏婚 小说大三 玄夜 小说魔头 云过是非 小说小说食百度书城免费阅读网 小说一次爆炸将云舟意外送外大乾末年,天下纷乱,群雄并起,互相征伐,乱世如草芥。他人的路,他人的道,他人的信念,跟云舟背离时,他只选自己的路,自己的道,自己的信念,抉择自己的人生,不悔。 改朝换代,权谋攻伐,尔虞我诈,云舟试在天下破万法。分久必合,合久必分,终究沿着他的路一统天下。 从大乾、大宁,到大永,从北桓、西延、南离、到东贤,愿天下再无饥馑,再无乱战,再无不公。 樱花落在玫瑰园里,一场伺机而动的较量即将开始。一位小家族出身的李星幼时父母便不知所踪,由于父亲犯下的错,使得他倍受同族欺凌。资质平平的他在炼丹方面却天赋卓绝,偶然得到一门顶级功法,书中竟有强大的书灵,在书灵的悉心指导下,他的修为也一日千里,他立志要成为大陆最强修仙者,为自己正名。酆都鬼门大开、黄泉河巨藤生长、富士山喷出拉普达城、达尔瓦扎坑洞崩塌、胡斯卡古堡发出怪笑声…… 世界大变,出现闻所未闻的怪物,人类生存堪忧,无知少年誓要揭开地球的秘闻,踏上金字塔顶峰! 【喜欢就点个收藏吧,各位看官】未来世界,一款名为超神空间的游戏横空出世! 人类可以自由进入超神空间,进行修炼升级打宝炼器,并且能在虚拟和现实中自由穿梭,将游戏中的等级和宝物带回现实! 沈明为了救治母亲的癌症,踏入超神空间寻找药物,逐渐从一个人人喊打的小人物,成长成为天下无双的万界之主! 恢复记忆的他发现世人皆想要他命,幸得先祖玉皇大帝传授改良功法和师兄秦始皇嬴政馈赠,然而他发现这倒霉功法突破方式太过奇葩,有人修仙靠灵气,有人修仙靠仙气,他修仙居然靠挨揍。在蓝星他靠挨揍不断突破,报家仇、平内乱、一统天下,荡平蚩尤余孽,破道成仙。 他以这倒霉功法重踏仙途,机缘巧合之下发现了这倒霉功法的BUG,为求突破到处抓壮丁,只为用他们的攻击换取突破机缘,开启挂机突破模式。 随着等级越来越高,寻常壮丁已然不能满足他的需求,他把魔爪伸向仙魔妖域,闹得仙魔妖域人心惶惶,仙帝也退避三舍。 “妖帝!张青那厮又来了!” “什么?!那家伙又来抓壮丁了?!快开启妖族大阵!” 防道仙师是他自己起的仙号,但仙魔妖域都称他万恶奴隶主! 他的仙途格言是:修为再高也怕菜刀?你把菜刀放下!用仙器!我需要一顿酣畅淋漓的胖揍!江鸿只是在课堂上看了一会西游记,没想到看着看着 睡着后竟然穿越了! …… 不对,这一群和尚是谁啊! 不对,我的声音怎么变了! “明日玄奘法师就要去求取真经了,可真想跟着啊。” 什么,这旁边和尚说的是什么啊! 江鸿忧愁的摸了摸自己的头,顿时爆了粗口 谁给我头发剃了,我怎么成和尚了。 还有,这桌子上的《西游记》是认真的嘛! ……郑重声明:东北大老李作品目前仅授权17K网站发表,非经本人书面授权,不得转载! 这是一部纯搞笑题材的小说,全篇将3000年后发生的一个个荒诞、离奇、搞笑的故事有机的串为一体,时而幽默,时而搞怪,时而惊悚,时而穿越,大进大出,大开大合,读时会让人有一种欲罢不能的畅快感! 做为一篇充满正能量的搞笑小说,作者延续了以往作品轻松诙谐的写作风格,让读者在读后发出会心微笑的同时,更会引发读者对人生意义的再度思索! 本作品不泛黄,不发黑,不暴力,语言风趣流畅,老少咸宜,不论是茶余饭后,还是枕边、厕前,做为除愁、解烦、解馋、解懒、解心宽的开心果,绝对值得一读! 张元清,河南人氏。生于明嘉靖三十六年,其祖上有恩于朝廷,特在县城造一府邸,祖上为防日后祸乱,又起造城墙,招兵买马,收募官员,名为张氏城府。万历十一年,山东一带陈希真等贼人作乱,朝廷大将身死,朝廷发一招贤榜,元清观后与村中几个玩伴前往京城,领数万军马征伐。互有伤亡,终平定匪患。元清遇一道人,道人送三粒仙药号能长生。元清服下一粒,给心中情人李金凤及好友胡志杰服下一粒,张元清于老家欢快数年,后遭数件坏事,其姑祖母认定屋子风水不好,全家搬至浙江万央镇。后张元清又经历抗击满清和洋人之战,期间李金凤身死。清政府退位后,城府被迫关封,张元清去伏仙山求道。二十年后张元清下山云游。眼下正是抗日全面爆发,元清加入以王正终为首的青平山义军,与日寇周旋,后抗战胜利,义军关寨解散,张元清归隐于青锋山修道。结识了六位道友,在一天夜里做一梦,与一群黑影打斗,却看不清他们脸面,张元清背靠一堵墙持剑自尽,张元清惊醒……本作品已经废除,特此告知书友
千云落 宠物小精灵之无敌人生 爆炸王朝 我家娘子毁天灭地 我用卫生纸拯救世界 死国1学院篇 玄幻:我的女帝徒弟要黑化 一壶酒,浮世三千 江湖潇湘 影视世界从一千万开始 我在诡异世界开宝箱 徒游者万古长情 天庭打工仔 郑熙破面撞物异世人生巅峰 我的皇室血统 日星游记 我的都市传说 世末日记 穿越之大侠宋青书 末日觉醒我在末世躺平了 尝试双飞 小说 hp布莱克家主母 莫莫私语 小说 藏婚 小说 一开始杀了全班进了监狱的小说 尝试双飞 小说 数码无限 外滩十八号 小说 宠 小说 剑修 小说 啊老公我要生了小说 默爱成殇 三月有桃花 小说 异界 搞笑小说 异界 搞笑小说 date a live小说下载 hp布莱克家主母 莫莫私语 小说 超级饭店 79小说 百度书城免费阅读网 小说 魔头 云过是非 小说 啊老公我要生了小说 跪侍 会所 小说 飞刀幻影+执往昔+小说 清如许 小说 小说 女 绰号 跪侍 会所 小说 小说 盗情 剑修 小说 date a live小说下载 啊老公我要生了小说 跪侍 会所 小说 脸皮 小说下载 啊老公我要生了小说 默爱成殇 三月有桃花 小说 宠 小说 剑修 小说 清如许 小说 热龙 小说 默爱成殇 三月有桃花 小说 剑修 小说 啊老公我要生了小说 百度书城免费阅读网 小说 hp布莱克家主母 莫莫私语 小说 重生之极权皇后 00小说 小说食 小说 盗情 大三 玄夜 小说 逆鳞 骑着蜗牛去旅行 小说 飞刀幻影+执往昔+小说 剑修 小说 大三 玄夜 小说 小说食 小说 盗情 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 我有一只大章鱼 武者修罗 洪荒!开局误入大佬群 末世:开局战地崛起 被仙界除名竟成妖族王者 百度 百度 百度 百度 百度 小说没想到 你还是个光板子 军事小说 火力quanji 下载 小说没想到 你还是个光板子 清如许 小说 热龙 小说 异界 搞笑小说 清如许 小说 数码无限 外滩十八号 小说 藏婚 小说 小说 女 绰号 小说 女 绰号 魔头 云过是非 小说 异界 搞笑小说 逆鳞 骑着蜗牛去旅行 小说 军事小说 火力quanji 下载 热龙 小说 御宠至尊 虾小米 小说 剑修 小说 跪侍 会所 小说 默爱成殇 三月有桃花 小说 数码无限 外滩十八号 小说 飞刀幻影+执往昔+小说 一开始杀了全班进了监狱的小说 脸皮 小说下载 重生之极权皇后 00小说 一开始杀了全班进了监狱的小说 神音系小说 尝试双飞 小说 小说 盗情 小说没想到 你还是个光板子 亚星官网 亚星官网 万利官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 欧博官网 欧博官网 欧博官网 欧博官网 欧博官网 欧博官网 欧博官网 欧博官网 欧博官网 欧博官网 欧博官网 欧博官网 欧博官网 欧博官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网 亚星官网