A complete HTML document
Let's build an HTML document step-by-step......
This tutorial focuses on:
- The core setup
- HTML document head
- HTML document title
- HTML document body
- An entire HTML document
The core setup
It all begins with the <html> tag. This tag signifies the start of a webpage. You must always begin your HTML code with this tag and all the other tags will go between <html> and it's closing tag </html>
HTML document head
The head section of an HTML document will actually not appear on a webpage but contains important information about the page such as the page's title and styles that will affect the page. The head section is set with the <head> tag which comes right after the <html> tag and the information about the page will go between <head> and it's closing tag </head>
HTML document title
The page's title is set with the <title> tag . The title can be seen in the top left corner of the web browser. If you look at the top left corner of your web browser window right now, you will see the title "Building an HTML document", as that is the title of this page. The <title> tag goes inside the <head> tag.
You can give your pages any title you want, but remember that the best titles are short and straight to the point.
HTML document body
The body section of an HTML document is where all the content is placed that will be seen on the page. The body section is set with the <body> tag which comes right after the <head> tag and the page's content will go between <body> and it's closing tag </body>
An entire HTML document
Piece-by-piece we have created an entire HTML document, very basic but it will do!
Focus on the structure of the above HTML document, understand it, memorize it. This same structure will apply to the code of all of the pages you will build, no matter how simple or complex. Also remember to always close tags in the right order like in the above example!
Now that you know fundamental HTML concepts and how to build a basic webpage, it's time to learn about working with text in HTML. Continue onward to our HTML text formatting tutorial!