bootstrap什么可以实现隔行变色
bootstrap中,可用“.table-striped”表格类实现隔行变色,该表格类用于在tbody标签内将奇数行的背景设为灰色,只需要给表格元素添加“class="table table-striped"”样式即可。
本教程操作环境:Windows7系统、bootsrap3.3.7版、DELL G3电脑
bootstrap什么可以实现隔行变色
通过添加 .table-striped class,将在 内的行上看到条纹。
可用“.table-striped”表格类实现隔行变色,只需要给表格元素添加“class="table table-striped"”样式即可。
示例如下:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
名称 | 城市 | 邮编 |
---|---|---|
Tanmay | Bangalore | 560001 |
Sachin | Mumbai | 400003 |
Uma | Pune | 411027 |
输出结果: