html table標籤的使用

<tr> 標籤定義 HTML 表格中的行。

HTML 表單中有兩種類型的單元格:

  • 表頭單元格 - 包含表頭信息(由 th 元素創建)
  • 標準單元格 - 包含數據(由 td 元素創建)

th 元素內部的文本通常會呈現爲居中的粗體文本,而 td 元素內的文本通常是左對齊的普通文本。

<table border="1">
  <tr>
    <th>Company</th>
    <th>Address</th>
  </tr>

  <tr>
    <td>Apple, Inc.</td>
    <td>1 Infinite Loop Cupertino, CA 95014</td>
  </tr>
</table>

Company Address
Apple, Inc. 1 Infinite Loop Cupertino, CA 95014

<tr> 表示行

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章