The HTML elements

This is a reference page, i.e., look at the contents and then come back to it when we need to.

An HTML element instructs the browser to do something with its content. Elements most often look like “<tag-name> element content </tag-name>”. Our template uses a few html elements:

HTML has many other types of elements (full list). However, only a few elements are really needed to write most static web pages. These are the most common ones:

organization elements

We use this element to split our pages in nested blocks.

elements about text

The ‘bold’ and ‘italics’ elements affect don’t affect the content of the document, which is the function of HTML, but only its appearance, which is a function of CSS. Although these elements are still accepted, it would not be surprising if in the future they are removed from HTML.


Example code:


Result:

This is bold,
this is in italics,
and this is red.


elements about lists


Example code:


Result:

Search engines:


elements for css or javascript

self-closing elements

These are elements that do not have content; they are also called empty elements.

comment elements

If we are having troubles commenting out a section of html code, enclose it in a division:


instead of this…


do this…