//对于 Bootstrap 3.0
For Bootstrap 3.0:
// class="col-md-*" 其中的*表示列的宽度
With twitter bootstrap 3 use: class="col-md-*"
where * is a number of columns of width.
-
<tr class="something">
-
<td class="col-md-2">A</td>
-
<td class="col-md-3">B</td>
-
<td class="col-md-6">C</td>
-
<td class="col-md-1">D</td>
-
</tr>
//对于 Bootstrap 2.0
For Bootstrap 2.0:
// class = "span*" 其中的*表示列的宽度
With twitter bootstrap 2 use: class="span*"
where * is a number of columns of width.
-
<tr class="something">
-
<td class="span2">A</td>
-
<td class="span3">B</td>
-
<td class="span6">C</td>
-
<td class="span1">D</td>
-
</tr>
// 如果有<th> 元素,在 th 上设置同样有效。
** If you have <th>
elements set the width there and not on the <td>
elements.
没有亲自试过,不过觉的 Twitter 的工程师真是脑洞大开。