Images, Figures & Figure Captions
Images
The img
tag defines an image in an HTML page and has two required attributes: src
and alt
. Images are not technically inserted into an HTML page. Rather images are linked to HTML pages. The img
tag creates a holding space for the referenced image.
Image without an Alignment
Image Center Aligned
Figures and Figure Captions
The figure
tag specifies self-contained content, like illustrations, diagrams, photos, code listings, etc. While the content of the figure
element is related to the main flow, its position is independent of the main flow, and if removed it should not affect the flow of the document.
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.