HTML4 HTML5
Embeds external resources, such as media files (e.g., PDF, audio/video) or interactive applications.
Void (self-closing) element – does not have a closing tag.
Attributes:
src="..." - (Required) Path to embedded file or resource.
type="..." - MIME type of embedded resource (e.g., application/pdf, image/svg+xml).
width="..." - Width of embedded area (in pixels or percentage).
height="..." - Height of embedded area (in pixels or percentage).
Code:
The browser will interpret this code as follows: