Computer >> Hướng Dẫn Máy Tính >  >> Lập Trình >> HTML

Thêm chú thích (caption) cho phần tử <figure> trong HTML5

Để thêm chú thích cho phần tử <figure>, dùng thẻ <figcaption>.

Ví dụ

Bạn có thể chạy mã sau để thêm chú thích cho phần tử <figure> trong HTML5:

<!DOCTYPE html>
<html>
  <head>
    <title>HTML figcaption Tag</title>
  </head>
  <body>
    <figure>
      <img src="https://www.tutorialspoint.com/videotutorials/images/tutorial_library_home.jpg" />
      <figcaption>Thư viện hướng dẫn Tutorials Point</figcaption>
    </figure>
  </body>
</html>