HTML <tr> tag

Usage

Defines a table row within a table. Each row can contain one or more table cells (td).

Example

Code:

<table border="1">
<tr>
<td>Row 1, cell 1</td>
<td>Row 1, cell 2</td>
</tr>
<tr>
<td>Row 2, cell 1</td>
<td>Row 2, cell 2</td>
</tr>
</table>

Output:

Row 1, cell 1 Row 1, cell 2
Row 2, cell 1 Row 2, cell 2

Required Attributes

  • none

Optional Attributes

  • align - right, left, center, justify, char - specifies the text alignment within the row cells
  • char - specifies the character that the text should be aligned around; not supported by many browsers
  • charoff - the number of pixels to offset the alignment by; again not supported by many browsers
  • valign - top, middle, bottom, baseline - the vertical alignment of the text

Core Attributes