HTML stands for HyperText Markup language, and its basic function is providing a structure for a web page. It consists of tags that help create the structure with their various uses. Some of which includes;
<img> with closing tags for most.
These tags are divided into several categories. Some of them are for presentation purposes. For instance, the
<b> tag is for making a text bold.
However, some other tags establish the meanings of the various elements used. For instance, the
<p> tag tells the browser that whatever text enclosed within the
<p> tag is a paragraph and should be treated as such. This concept is termed HTML Semantics.
Therefore, HTML semantics refers to HTML tags that aren't just presentational but include meaning and enhances the understanding/interpretation of the browser and anyone reading the code.
Next, see some HTML tags existing alongside their meanings/uses.
List of HTML Tags and Uses
<html></html>: It specifies or tells the browser that the type of document is an HTML document.
<head></head>: It consists of sub-tags such as:
<script>tags that provide information about the document, set the title of the document that can be seen in the URL section of the browser, link files to the document or external APIs.
<body></body>: It consists/encompasses all the code that is displayed or viewed in the browser (what is visible to the users).
<H1></H1>: It tells the browser that the text enclosed by the tags is to be treated as a first-level heading with a larger font size attributed to an
<H2></H2>: It tells the browser that the text enclosed by the tags is to be treated as a second-level heading with a larger font size attributed to an
<H3></H3>: It tells the browser that the text enclosed by the tags is to be treated as a third-level heading with a larger font size attributed to an
<H4></H4>: It tells the browser that the text enclosed by the tags is to be treated as a fourth-level heading with a larger font size attributed to an
<H5></H5>: It tells the browser that the text enclosed by the tags is to be treated as a fifth-level heading with a larger font size attributed to an
<H6></H6>: It tells the browser that the text enclosed by the tags is to be treated as a sixth-level heading with a larger font size attributed to an
<p></p>: This tag defines a text as a paragraph. It starts the text on a new line with a default font size of 16px.
<br></br>: This tag defines a line break. When used between two HTML elements, it demarcates the elements from each other by introducing a line of space between them.
<hr>: This stands for a horizontal line. When it is used, it introduces a line horizontally.
<!- ... - >: It is used to include comments in an HTML code that provides additional information about the code and what it does.
<a></a>: This tag is called anchor links and includes links to an HTML document.
<img>: This tag is for including images in HTML documents.
<b></b>: This tag is used for making a text bold.
<i></i>: This tag is used to make a text italics.
<table> <tr> <td> <td> <tr> </table>: This tag is used to define a table with rows and columns.
<font size></font>: This tag is used to increase or decrease the font size of an element.
<dl> <dt> <dd> </dl>: It is used for specifying a definition in a list and indenting each definition.
<div></div>: This tags is called a division tag. It allows you to divide your HTML code into several contents with several enclosed subtags.
<span></span>: This elements is used to wrap inline text usually in a
<thead></thead>: In representing a table, it can be used to single out or represent the head/title of the table that contains several rows and columns.
<tbody></tbody>: This tag helps group the table's content that represents the content of the table.
<tr></tr>: This tag defines the rows in a column and defines the structure for the row.
<td></td>: This tag defines the content in the row of the table.
<ul></ul>: This tag defines an unordered list.
<li><li>: This tag is used to create several lists of items.
<ol></ol>: This tag defines an ordered list.
<strong></strong>: This tag makes a text bold, telling the browser to treat it as an important text.
<abbr></abbr>: This tag defines an abbreviation.
<address></address>: It is used to define contact information on the website.
<embed></embed>: It defines a link to an external resource.
<iframe><iframe>: It is used to embed an external link to a document inside another document.
<footer></footer>: It defines content/information at the bottom of the document.
<main></main>: It is used to define the main section of the document.
<input></input>: It is used to define an input field for entering data by the user.
<param></param>: It defines parameters in an
<output></output>: It is used to define the output of a program or calculation.
In this article, you learned about HTML semantics, what it is, and some of its uses. You also covered forty (40) different HTML tags with their various meanings/uses.