HTML: The Markup Language (an HTML language reference)

trtable row # T

The tr element represents a row of cells in a table.

Permitted contents #

zero or more of: one td element, or one th element

Permitted attributes #

global attributes
Any attributes permitted globally.

Additional constraints and admonitions #

Tag omission #

A tr element must have a start tag.

A tr element’s end tag may be omitted if the tr element is immediately followed by another tr element, or if there is no more content in the parent element.

Permitted parent elements #

table, thead, tfoot, tbody

DOM interface #

interface HTMLTableRowElement : HTMLElement {
  readonly attribute long rowIndex;
  readonly attribute long sectionRowIndex;
  readonly attribute HTMLCollection cells;
  HTMLElement insertCell(optional long index);
  void deleteCell(long index);

Typical default display properties #

tr {
display: table-row;
vertical-align: inherit;
border-color: inherit; }