table

< html‎ | elements
Jump to: navigation, search

table

This article is Not Ready.


W3C Recommendation

Summary

The <table> element is a wrapper for an HTML table. It defines the start and end of a table, and as such can contain other table elements, such as <tr>.


Overview Table

DOM Interface HTMLTableElement

The <table> element is a container for HTML tables, which are used to markup tabular data.

Tables are also often used for laying out web pages, but this is a bad practice that should not be done anymore. Use <div> and <span> instead for layouts.


Compatibility

Do you think this data can be improved? You can ask to add by opening an issue or make a pull request.

Desktop

FeaturesChromeFirefoxInternet ExplorerOperaSafari
Basic support
1.0
Yes
1.0
Yes
4.0
Yes
7.0
Yes
1.0
Yes

Mobile

FeaturesAndroidFirefox MobileIE MobileOpera MobileSafari Mobile
Basic support
1.0
Yes
1.0
Yes
6.0
Yes
6.0
Yes
1.0
Yes

Examples

This example uses the tbody element with the table, td, thead, and tr elements to create a table with the first row in the table head and the second row in the table body.

HTML

<table>
  <thead>
    <tr>
      <td>
        This text is in the thead.
      </td>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>
        This text is in the tbody.
      </td>
    </tr>
  </tbody>
</table>



Related specifications

Specification Status Related Changes
HTML 5.1 Editor's Draft
[ ]

See also

Related articles

HTML


















































… further results

Tables








  • table