HTML HTML Tutorial HTML Forms HTML Graphics HTML Media HTML APIs HTML Tags



HTML Tag: th

The HTML tag th stands for table header cell. It is used to define a header cell in an HTML table. The th tag is used to define the header cells for a table row or column. The th tag is used in conjunction with the tr (table row) and td (table data) tags to create a table.

Brief Explanation about HTML Tag: th

The th tag is used to define the header cells for a table row or column. The th tag is used to define the header cells for a table row or column. The th tag is used in conjunction with the tr (table row) and td (table data) tags to create a table. The th tag is used to define the header cells for a table row or column. The th tag is used in conjunction with the tr (table row) and td (table data) tags to create a table.

The th tag is used to define the header cells for a table row or column. The th tag is used in conjunction with the tr (table row) and td (table data) tags to create a table. The th tag is used to define the header cells for a table row or column. The th tag is used in conjunction with the tr (table row) and td (table data) tags to create a table.

Code Examples in Per Tags

Here are some examples of how to use the th tag:

First Name Last Name Age
John Doe 25
Jane Doe 30

In the example above, the th tag is used to define the header cells for the table. The tr tag is used to define the table rows, and the td tag is used to define the table data cells.

Here is another example:

Monthly Sales
Month Sales
January $1000
February $1500

In the example above, the th tag is used to define the header cells for the table. The colspan attribute is used to span the header cells across two columns. The tr tag is used to define the table rows, and the td tag is used to define the table data cells.

References

Activity