Coding with HTML – 101 Basics Some handy things to remember while coding with HTML:

The basic structure of a HTML document always looks the same:

<!DOCTYPE html>


HTML documents are made up of HTML elements. Elements are pieces of content surrounded by HTML tags.

Each tag is an instruction to your browser, telling it how to display the content between the opening and closing tags on-screen.

HTML tags are written inside angle brackets ( < > )

You have an opening and closing tag, so your browser knows when the instruction starts and stops.

You can always spot a closing tag because it contains a forward slash ( )

If there is no content to put between two tags, you use a self-closing tag, which is an opening and closing tag rolled into one.

Tags are always written in lower-case.

You can nest HTML tags inside each other. Just don’t forget to close your tags.

When you open a new tag you should always indent your code by pressing Tab on your keyboard. This makes it easier to read your code.

If you want to give your browser extra instructions or information about a HTML element, you can use various HTML attributes.

Attributes go inside the opening tag. They always have a name and a value, which you set using the equals sign ( ) and double quotes ( ” “ ).

Web pages normally have more than just words and pictures on them.

Keep reading to find out how to change the layout and design of your page. :-)