Coding with HTML – 101 Basics

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. :-)

Connected through code, Choose Your Platform!

About the Author: Bernard Aybout

In the land of bytes and bits, a father of three sits, With a heart for tech and coding kits, in IT he never quits. At Magna's door, he took his stance, in Canada's wide expanse, At Karmax Heavy Stamping - Cosma's dance, he gave his career a chance. With a passion deep for teaching code, to the young minds he showed, The path where digital seeds are sowed, in critical thinking mode. But alas, not all was bright and fair, at Magna's lair, oh despair, Harassment, intimidation, a chilling air, made the workplace hard to bear. Management's maze and morale's dip, made our hero's spirit flip, In a demoralizing grip, his well-being began to slip. So he bid adieu to Magna's scene, from the division not so serene, Yet in tech, his interest keen, continues to inspire and convene.