HTML Tags

HTML is basically written in the form of HTML elements consisting of tags enclosed in angle brackets.

(For example <html>)


HTML tags most commonly come in pairs like <h1> and </h1>,where <h1> called opening tag (Start tag) and </h1> called closing tag (End tag).

Each and every tag consists of a separate tag name, followed by a list of tag attributes (if necessary),

HTML tags are not case sensitive i.e. <HTML> is same as <html>.

There are two kinds of tags.

Physical Tags:

Provide specific instructions on how to display the text they enclose. 

For example,

<b>: Makes the text bold. 

<big>: Makes the text usually one size bigger than what’s around it. 

<i>: Makes text italic. 

But nowadays, CSS replaces physical tags.

Logical Tags:

Logical tags are designed to describe (to the browser) the enclosed text’s meaning.

For example,

<strong>ProgrammingTute</strong>

By placing text in between these tags you are telling the browser thatthe text in between these tags has some greater importance. By default all browsers make the text appear bold when in between the <strong>and </strong> tags.

Some of the other important tags are

Line Breaks:

The <br> tag forces a line break wherever you place it. It is similar to single spacing(new line) in a document.

Example:

<p> Programming <br> Tute </p>

Output:                           

Programming

Tute

Horizontal Rule:

The <hr> element is used for horizontal rules that act as dividers between sections.

Example:

<hr width="100%" align="left">

Output:


 

Posted on July 12, 2014 in HTML

Share the Story

Response (1)

  1. Negro
    February 18, 2016 at 3:44 am · Reply

    That’s the best answer by far! Thanks for cobirtnuting.

Leave a reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Back to Top