Web Design / HTML

  1. Home
  2. Computing & Technology
  3. Web Design / HTML

<th></th>

By Jennifer Kyrnin, About.com

<th> description:

The <th> element defines table header cells.

<th> Web Browser Support:

<th> Attributes:

<th> End Tag:

</th> optional

Contents:

Usually text. The following tags are valid within the <th> tag:
a, abbr, acronym, address, applet, b, basefont, bdo, big, blockquote, br, button, center, cite, code, dfn, dir, div, dl, em, fieldset, font, form, h1, h2, h3, h4, h5, h6, i, iframe, img, input, isindex, kbd, label, map, menu, noframes, noscript, object, ol, p, pre, q, s, samp, script, select, small, span, strike, strong, sub, sup, table, textarea, tt, u, ul, var

<th> Valid Context:

The <th> tag is valid within the following tags:
tr

<th> Usage:

  • basic table
    <table border width="200">
    <tr><th>
    header 1
    </th><td>
    column 2
    </td></tr>
    </table>

<th> Special Notes:

  • The default look and feel of a header cell is usually centered with bold text.
  • While you can omit the ending tag, tables are easier to read when they are present, and it gives you better control over style tags.
  • When using nested tables, if the th tags are not closed, the browsers may become confused as to which table elements go with which table.

More <th> Information:

Return to XHTML element (HTML Tags) Library

Explore Web Design / HTML

About.com Special Features

Build Your Own Website

Step-by-step advice on how to do everything from choosing a Web host to promoting your content. More >

Connect Your Home Computers

Easy ways to connect two computers for networking purposes. More >

Web Design / HTML

  1. Home
  2. Computing & Technology
  3. Web Design / HTML

©2009 About.com, a part of The New York Times Company.

All rights reserved.