html - Bootstrap 2 (span) 与 Bootstrap 3 (col-md)

标签 html css twitter-bootstrap twitter-bootstrap-3

我曾经使用 Bootstrap v2.0 在 asp.net mvc web 应用程序上工作,我使用以下内容将屏幕分成 3 个部分 4x4x4 :-

<div class="box span4">
...
</div>
<div class="box span4">
...
</div>
<div class="box span4">
...
</div>

在启动 v3.0 时,我似乎需要执行以下操作:-

 <div class="row">
    <div class="box col-md-4"></div>
  <div class="box col-md-4"></div>
  <div class="box col-md-4"></div>
</div>

所以我有关于上述两个问题:-

  • 在 bootstrap v2.0 上使用 span 与在 bootstrap v3.0 上使用 col-md 效果一样吗?

  • 在 bootstrap v3.0 上 col-md-4 究竟做了什么??..这是否意味着 div 在大中型屏幕上将占据 4 列,而它会在小屏幕和超小屏幕上向下移动吗?

最佳答案

其实不同的地方在于断点。 span 在 767px 处打断布局,而 col-md- 在 991px 处打断结构。

col-md-4表示一个div在大中屏上占3列,992px以下采用100%。

关于html - Bootstrap 2 (span) 与 Bootstrap 3 (col-md),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31215929/

相关文章:

html - 响应式导航错误

twitter-bootstrap - 安装 bootstrap 到 grails

javascript - Bootstrap Datepicker 显示的月份数

css - 在 CSS 中覆盖继承的 h1 和 h3 值

php - 使用 ajax 自动更新 .txt

jquery - 为什么当我使用 jQuery 自定义插件将 src 添加到图像时,该段落被下移了?

CSS变换源问题

html - 为什么列表项与其父项之间有空格分隔?

HTML 表格 - 列宽自动调整

css - rgba 字母周围奇怪的轮廓