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
沈阳做网站公司镇江网站公司工控企业信息安全深圳 网站制作云网站系统国家网络安全体系个人网络安全年度报告公司网络安全的通知国家信息安全局网络营销的最新特点联通网络安全广州外贸营销型网站宁波信息安全公司排名网站网页网站设置那里如何设计关键词和关键词密度能更好的被百度收录甘肃网站制作公司有哪些网络安全周简介哪个大学信息安全网站没更新广东信息安全公司侧导航网站途牛网的营销模式重庆网站开发商城678营销系统账号政府网站 欣赏政府网站 欣赏沈阳做网站公司网络安全 打击南京网站设计公司如何网络营销他,虽是庶子,但却是王国八大贵族之一格林家族内定继承人,长相虽平凡,但他的心不甘于平凡。虽然被人陷害、不得不被流放追杀,但天降系统,助他成神。且看一个小领主如何借助系统和奇遇,一步步崛起,最终称霸大陆..... 江城穿越平行世界,绑定神级科技系统,系统的触发条件是让他独自研发一项改变世界的发明。 于是他选择了可回收火箭,打造猎鹰九号升级版,在苦心研究五年之后,所有测试结果均为完美,成功率百分之九十五,一经上市,保守年收入五十亿。 为了拿到投资,他将自己的所有理念模型,包括他获得的荣誉电邮到了摩根银行,竟然真的得到了回信,并且对方愿意前来核验。 恰逢相亲走错桌,遇到年轻貌美的投行女大佬,没想到摩根银行的投资条件是让这项技术为M国专利,江城愤然拒绝。 摩根银行为此和媒体恶意渲染抹黑回收火箭技术不可能实现,想要毁掉江城。 关键时刻,看到一切的相亲女大佬林若溪在媒体面前支持江城,并且怒投十亿! 三个月后,当猎鹰九号升级版问世登上太空,并且成功返回之后,全世界都震惊了!魏和平在迷茫中穿越到了平行世界,无意中发现了系统的存在,他该勇往直前,还是猥琐发育,我决定要安全的浪。(本小说以民间传说为基础改编而成!其中剧情皆为虚构,切勿当真!) 这个世界真的如我们所了解的那么简单吗?那些传说中的事物真的就不存在吗?若传说就是事实,那么又是谁在默默的守护我们呢? 都说哪有什么岁月静好,不过是有人在替我们负重前行。那么这负重者都有谁呢? 今天我来告诉你们,其中一个便是自唐朝就成立的神秘组织--镇诡司!凡天下有诡现世,镇诡司必首当其冲,伏之,镇之,掩之!夜没寒烟起,雪舞蝶光月,连踏青云处,城破不归人。古神大陆自诞生以来便流传着一个传说,命运之门会在一个时代结束时降临,得见命运之门者,可以登临神境,进入命运之门者,可获永生。 …… 杨凡天生道骨,却被家主算计和爱人偷袭,落了个修为全失,道骨被夺的下场,正当奄奄一息时,遇到了曾经见过命运之门的鬼圣阴无虚,并夺了对方的一身机缘…… 境界划分:炼体、苦海、神宫、仙台、破虚、同体、大圣、大帝、半神、神……天选降临,蓝星各国分为不同文明,每个文明抽取一百人进入天选空间,以神话底蕴为力量源泉,展开竞争! 西方天使、希腊众神、克苏鲁神话、埃及法老、樱花国八百万神…… 唯独,没有炎黄神话! 蓝星之上,炎黄经历文明断层,举头三尺无神明。 直到云泽穿越而来。 云泽:“我炎黄乃上古文明!上有盘古开天辟地,下有仙神护国安民!” 蓝星诸国:“别搞笑了,炎黄无神,众所周知!” 半年后…… “这天选不公平!炎黄本就是高级文明,随便挑个神就能碾压我们,这还怎么玩!”我只想安安稳稳送个外卖,哪想到有一天居然真的黄袍加身! 还是在异界!! 送外买送到异界的恐怕只有我一个了吧? 看着满目荒凉的异界,杨一暖苦笑一声,开始了异界探险之旅… 外卖是不会再送了,星际贸易才是我的主业! 玻璃球换黄金,香水换翡翠,一个黑心倒爷就此诞生… 异界投资建工厂,寻宝探矿搞开发,从今天开始,我就是杨总! 新世界首富,异世界征服者,就此诞生!!1982年的冬天,阳历11月22日,小雪。在这天,一名女婴降生在了一个背靠青山的小村庄里最西头的三间茅草屋里。父亲给她取名为“晓敏”。 四年后,也是一个冬天,父母决定把她送走,从此她的命运便开启了另一扇大门…… 童年缺失的东西,就好像是你心里有个洞,你总是会有意无意的,不由自主的去填它,最后你会发现它是个怎么也填不满的无底洞。每个人一出生便会哭泣,然后才会笑,因为人生不易。 苦难可以磨炼人的心智,悲伤最后会化为元气包裹我们的心,不再受到伤害。 我们都是普通人,我们都一样平凡,只是不一样的经历演绎不一样的命运,绘画不一样的人生! 无论怎样,请保持拥有随时微笑的能力,因为你得精彩的活着!男主明子皓是一位刚刚毕业的大学生,刚刚打算步入社会的他在一次偶然的机遇下他发现了不为人知的秘密,他的人生从此发生了翻天覆地的变化……
南京网络营销外包 信息安全规划 网站维护收费 宁波信息安全公司排名 厦门网站开发 邢台网站制作有哪些 网站备案填写的《信息安全管理协议》是去了备案的地方再填吗 合肥做网站 qq网络营销策划 信息安全对嵌入式攻击 建网站流程 沈阳做网站公司 上海网站建设企 国家信息安全局 哈尔滨做平台网站平台公司 滴滴营销活动 国保联盟信息安全技术,-1 公司网站设计与制作 哪个大学信息安全 网站域名组成 柳州建网站 视频网站建设方案 微信营销软件 封号吗 网络安全信息化办公室 营销专业网站 传统营销的理论基础 网络安全保卫局官网 建网站流程 杭州网站制 太原免费网站建设 安庆网站制作 网站维护收费 江苏信息安全网 信息安全方面主要工作 买网站空间外贸营销策划 双语网站建设 深圳网络安全快速考证 网站推广费用 网络信息安全范畴 信息安全等级保护系统建设的安全实施方案应包含以下哪些内容