HTML td tag
- 24-07-2022
- Trung Minh
- 0 Comments
The td tag defines a standard cell in an HTML table.
An HTML table has two types of cells:
- Header cells: cells that contain title information, use the th tag to create a title box. Text in the title box will be bold and centered by default.
- Standard cell: contains the data of the table, use the td tag to create. Text in standard cells will print normally and are left aligned by default.
Use the td tag in conjunction with the table and tr tags to create tables in HTML.
Using
Example : Use a combination of the td tag with the table and tr tags to create a simple table.
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> </head> <body> <h1>Học html miễn phí tại web888.vn</h1> <table border="1px"> <tr> <td>Tên Thẻ</td> <td>Mô tả</td> </tr> <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> </table> </body> </html>