
TAGS
-
The basic structure of an HTML document includes tags.
-
Tags surround content and apply meaning to it.
-
Tags are contained within angle brackets or carets: <>
We're going to add a few basic tags to our document:
<!DOCTYPE html>
This is a document type declaration that lets your web browser know which version of HTML you're using.
It is self-closing since it doesn't nest any content in between it.
<body> </body>
Whatever lies between the <body> and </body> is the main content of the document that will appear in the browser window.
<html> </html>
The <html> tag alerts the browser that everything that lies in between it and </html> forms an HTML document.

-
Once you run this code, you'll see that nothing changes.
-
This is because the purpose of HTML is to apply meaning, not presentation, and this example has now defined 3 fundamental elements of a web page:
-
The version of HTML you're using
-
The main content of the page defined by the body tags
-
The fact that this is an HTML document
-

ELEMENTS
-
Elements are what make up web pages.
-
Tags are a part of an element.
-
For example: everything that is in between (and includes) the <body> and </body> tags is the body element.
