I want to make an HTML table, but honestly, it doesn't need a <thead>
. Is it optional to have a head? Sorry if the is beginner level.
Do we need the tag in HTML tables?
Asked
Active
Viewed 571 times
0
FlipFloop
- 1,233
- 1
- 14
- 25
-
1
Answer you can find in this article.:)
http://stackoverflow.com/a/5395291/4275093
– NormundsP
Dec 13 '15 at 20:28
-
HTML tables do not require `thead` elements.
– Rick Hitchcock
Dec 13 '15 at 20:32
2 Answers
2
Is is optional but explicitly grouping header rows with THEAD, will give the browsers the ability to include the header rows if there is a need to print tables with multi pages. This will also give you the possibility for a large table to have a scrolling body and static header rows. Many browsers support THEAD, so you can use it without problems.
That sad, it's up to you if you want to use it or not.
Franco
- 2,309
- 1
- 11
- 18
1
As Franco said, it is optional. However, if you start using JQuery plugins, say like DataTable ( http://www.datatables.net/ ) will expected them to be there and will give errors if they are not.
Bindrid
- 3,655
- 2
- 17
- 18
Asked
Active
Viewed 571 times
0

FlipFloop
- 1,233
- 1
- 14
- 25
-
1Answer you can find in this article.:) http://stackoverflow.com/a/5395291/4275093 – NormundsP Dec 13 '15 at 20:28
-
HTML tables do not require `thead` elements. – Rick Hitchcock Dec 13 '15 at 20:32
2 Answers
2
Is is optional but explicitly grouping header rows with THEAD, will give the browsers the ability to include the header rows if there is a need to print tables with multi pages. This will also give you the possibility for a large table to have a scrolling body and static header rows. Many browsers support THEAD, so you can use it without problems. That sad, it's up to you if you want to use it or not.

Franco
- 2,309
- 1
- 11
- 18
1
As Franco said, it is optional. However, if you start using JQuery plugins, say like DataTable ( http://www.datatables.net/ ) will expected them to be there and will give errors if they are not.

Bindrid
- 3,655
- 2
- 17
- 18