如何在表格标题下添加边框底部或水平线

时间:2014-09-20 10:23:50

标签: html css

我想在 下面创建一个水平线。以下是我想要实现的目标

Table underline required

我使用以下html标记

创建了表格
<table>
      <tr>
        <th>Table</th>
        <th>&#37; of Time Index Used</th>
        <th>Rows in Table</th>
      </tr>
      <tr>
        <td>tweet_groups</td>
        <td>67</td>
        <td>20,488</td>
      </tr>
</table>

那么如何添加水平线?

3 个答案:

答案 0 :(得分:1)

tr:first-child{ border-bottom: 1px solid #555;}

答案 1 :(得分:1)

table tr:first-child{border-bottom:1px solid #000;}

答案 2 :(得分:1)

th
{
 border-bottom: 2px solid #000000;
}
相关问题