HTML tags.

Photo by Jackson So on Unsplash

HTML tags.

Tags play an essential role in the way our code comes out in the browser. Here are a few things you need to know about them.

·

2 min read

An HTML tag indicates the beginning and end of an HTML element. Tags are identified with <> (opening tag) </> (closing tag)

  • The opening tag <> : Indicates the beginning of a section in a page. They sometimes carry attributes. Attributes tell us more about the content of an element.

  • The closing tag</> : Indicates the ending of a section in a page.

There are basically two types of HTML tags.

  • The container tags ; <head> </head>, <title> </title>

- The empty tags ; <br> , <hr>

some HTML tags and their uses;

  1. <p> ...... </p>; indicate the starting of a paragraph.
<p> I love Apples. They make my day </p>
  1. <b> ..... </b> ; they make a character appear bold.
<b> They make my day </b>
  1. <i> ...... </i> ; they make a character appear italic. They can also be nested in another tag.

</p> <i> I wish to have an apple a day </i> to keep my doctor away </p>
  1. <sup>...... </sup>; they are called the superscript tags .

On the 4 <sup> th </sup> of may.

There are alot of HTML tags, don't get scared though because you'll only be using a handful of them. We would be covering lists and links on the next post.