HTML Terminology
When learning HTML, it's essential to understand some key terminology to help you better comprehend the concepts and communicate with other web developers. This section will introduce you to some common terms used when working with HTML.
Word
Definition
Tag
The start tag or closing tag. A tag is a keyword enclosed in angle brackets (< and >). Tags are used to define HTML elements and specify how the content should be displayed or structured. Tags usually come in pairs—an opening tag and a closing tag (e.g.,
<p>
and </p>
). Some elements, known as self-closing elements, do not require a closing tag, such as <img>
and <br>
. Content/Children
The content located in between start tags or closing tags. Children allow you to nest elements and create more complex HTML pages
Attribute
An attribute is additional information added to an opening tag to define its properties or modify its behavior. Attributes are included within the opening tag of an element and consist of a name-value pair, separated by an equals sign (=). Examples of common attributes include href, src, alt, class, id, and style.
Attribute value
The value of an attribute found after the = symbol, usually enclosed within " quotes
DOM
The document object model, often referring to an entire HTML document
Angle Brackets
< and > also called greater than and less than brackets.
Nesting
Nesting refers to the practice of placing one HTML element inside another. Proper nesting is essential to create well-structured and valid HTML documents
Opening Tag
A tag made from the angle brackets, with no slash, like so:
<h1>
. Opening tags can have attributes Closing Tag
A tag that is made from the angle brackets, wrapped around the tag name, and a slash at the start, like so:
</h1>
Element
An element refers to opening and closing tags, as well as the children or content within. Elements are the building blocks of an HTML document and define the structure and content of a web page.
What is the difference between an element and a tag?
You must be logged in use AI assessments