HTML th Tag

November 11, 2010 by: aBisona

Example

A simple HTML table, containing two columns and two rows:

<table >
<tr>
<th>Month</th>
<th>Savings</th>
</tr>
<tr>
<td>January</td>
<td>$100</td>
</tr>
</table>

Try it yourself »
(more examples at the bottom of this page)


Definition and Usage

The <th> tag defines a header cell in an HTML table.

An HTML table has two kinds of cells:

  • Header cells – contains header information (created with the th element)
  • Standard cells – contains data (created with the td element)

The text in a th element is bold and centered.

The text in a td element is regular and left-aligned.


Browser Support

Share and Enjoy:
  • Print
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • Blogplay
Have you found this script useful? Please support author by PayPal donation.
Filed under: HTML,Webmasters
Tags:

Leave a Reply