Tuesday, April 2, 2019

HTML: Basics Part-III


HTML: Basics  Part-III 

HTML Headings

These tags help us to give headings to the content of a webpage. These tags are mainly written inside the body tag. HTML provides us with six heading tags from <h1> to <h6>. Every tag displays the heading in a different style and font size. <h1> defines the most important heading. <h6> defines the least important heading.
Example:
<html>
<head>
                    <title> SumProgs </title>
</head>
<body>
          <h1> Hello SumProgs </h1>
          <h2> Hello SumProgs </h2>
          <h3> Hello SumProgs </h3>
          <h4> Hello SumProgs </h4>
          <h5> Hello SumProgs </h5>
          <h6> Hello SumProgs </h6>
</body>
</html>

Output:











HTML Paragraph
These tags help us to write paragraph statements in a webpage. They start with the <p> tag and ends with </p>. Here the <br> tag is used to break line and acts as a carriage return. <br> is an empty tag.
Example:
<html>
<head>
                    <title> SumProgs </title>
</head>
<body>
          <h1> Hello SumProgs </h1>
          <p>
                   An online portal for all future programmers <br />
                   An online portal for all future programmers <br />
                   An online portal for all future programmers <br />
          </p>
</body>
</html>

Output:






HTML Horizontal Lines
The <hr> tag is used to break the page into various parts, creating horizontal margins with help of a horizontal line running from left to right hand side of the page. This is also an empty tag and doesn’t take any additional statements.
Example:

<html>
<head>
                    <title> SumProgs </title>
</head>
<body>
          <h1> Hello SumProgs </h1>
          <p>
                   An online portal for all future programmers <br />
                   An online portal for all future programmers <br />
                   An online portal for all future programmers <br />
          </p>
          <hr />
<p>
                   An online portal for all future programmers <br />
                   An online portal for all future programmers <br />
                   An online portal for all future programmers <br />
          </p>
          <hr />
          <p>
                   An online portal for all future programmers <br />
                   An online portal for all future programmers <br />
                   An online portal for all future programmers <br />
          </p>
          <hr />
</body>
</html>

Output:

No comments:

Post a Comment