figure caption tag in html

The <figcaption> tag defines a caption for a <figure> element.
The <figcaption> element can be placed as the first or last child of the <figure> element.


<!DOCTYPE html>
<html>
<body>

<figure>
  <img src="../html/pic_trulli.jpg" alt="Trulli" style="width:100%">
  <figcaption>Fig.1 - Trulli, Puglia, Italy.</figcaption>
</figure>

</body>
</html>

Output:

Trulli

Fig.1 - Trulli, Puglia, Italy.

Comments

Popular posts from this blog

Introduction and Format of HTML

Headings In HTML

dfn tag in html