What are Elements?
An element is a part of a webpage. An element may
contain a data item or a chunk of text or an image, or perhaps
nothing. A typical element includes an opening tag with some
attributes, enclosed text content, and a closing tag.
The content of an HTML element is the information between the
opening and closing tags of an element.
Document Structure
HTML is organized into a family tree structure. HTML elements can
have parents, grandparents, siblings, children, grandchildren, etc.
Opening tag |
Closing tag |
Description |
<html> |
</html> |
The root element of an HTML document; all other elements are
contained in this..
|
<head> |
</head> |
Container for processing information and metadata for an HTML
document.
|
<title> |
</title> |
Defines the title of an HTML document. It is displayed in the
browser’s title bar or tab.
|
<body> |
</body> |
Container for the displayable content of an HTML document.
|