HTML tfoot tag
- 24-07-2022
- Trung Minh
- 0 Comments
The tfoot tag defines the footer content of the table.
The tfoot tag is used in conjunction with thead and tbody tags to specify each part of the table (header, body, footer).
Web browsers can use this element to allow scrolling of the body of the table without regard to thead or tfoot. In some cases where the table data is large and spans many pages, these elements can help thehead and tfoot be printed at the top and bottom of the page.
When using tfoot tags you must note that they must be children of the table tag, must be placed after all caption, colgroup and thead tags and must be placed before the tbody tag.
Using
For example , use the tfoot tag to specify the contents of a table.
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> </head> <body> <h1>Học html miễn phí tại web888.vn</h1> <table> <thead> <tr> <th>Tên Thẻ</th> <th>Mô tả</th> </tr> </thead> <tfoot> <tr> <td>Tổng</td> <td>3 Thẻ</td> </tr> </tfoot> <tbody> <tr> <td>a</td> <td>tạo siêu liên kết</td> </tr> <tr> <td>p</td> <td>định nghĩa một đoạn văn bản</td> </tr> <tr> <td>br</td> <td>ngắt dòng hiện tại</td> </tr> </tbody> </table> </body> </html>