The HTML5 tbody Tag

Grouping the body content for tables that are included within the HTML document is necessary. Hence the use of HTML5 <tbody> tag is also very important.

Using the HTML5 <tbody> tag has to be done along with <thead> and <tfoot> tags. Using these with the HTML5 <tbody> tag is needed to be able to determine the different parts of the table like the header, body and footer.

When the HTML5 <tbody> tag is used along with the other necessary elements, the browsers will be able to display the different parts properly and it would be possible to scroll the body separately from the header and footer. Even when printing out the page, the header remains on top of the page and footer is printed at the bottom, despite multiple pages.

When the use of <tbody> tag is compared in HTML5 and HTML4.01, there will be a lot of differences that have to be dealt with. Most of the attributes in HTML4.01 are no longer supported in HTML5.

The table below clarifies the attributes for HTML5 <tbody> tag.

Attribute

Value

Description

align

right
left
center
justify
char

This is no longer supported in HTML5

char

character

This is no longer supported in HTML5

charoff

number

This is no longer supported in HTML5

valign

top
middle
bottom
baseline

This is no longer supported in HTML5

The good thing about the HTML5 <tbody> tag is that it provides support for the Event Attributes and Global Attributes. It is also recognized in various web browsers like Internet Explorer, Google Chrome, Safari, Opera and Firefox.

Featured pages

Overview

Learn about HTML5 architecture, design principles and patterns on HTML5 Overview Tutorial. Become …

Tags

Learn about HTML5 tags and discover a new list of HTML5 tags. Find out about HTML5 tags support by…

Welcome

 Learn HTML5 development techniques, tips and tricks on our website. Find out what is required…

Date Time Picker

HTML5 forms use date and time controls regularly. HTML5 date and time controls are used by booking …