Web Development

HTML – HR Tag and Its Attributes With Syntax

This <hr> is the tag which draws a horizontal line across whole page, whenever it is specified it will draw the line.

The <hr> tag is singular tag, it means the <hr> tag does not contain closing tag. <hr> tag defined as,

<h3>Heading 3.1</h3>
<p> Hello World ! Learn HTML</p>
<hr>
<h3>Heading 3.2</h3>
<hr>
<p> Hello WOrld ! How are you?</p>

It can have attributes its attributes are given:

ParameterDescription
SizeSpecifies the thickness of the bar
WidthSpecifies the width of the bar in wither pixels or as a percentage
AlignIndicates how the bar should be placed on the page (left, centre, right)
NoshadeRemoves the shadow that normally appears below the bar
ColorSpecifies the colour of the bar; if omitted the default is a dark grey.

Try Yourself:

<html>
<head>
</head>
<body>
<h3>Chapter 1.</h3>
<hr width='100%' size='5px'>
<p>The quick brown fox jumps over the lazy dog. </p>

<h3>Chapter 2.</h3>
<p> I recooment you to poass this time on the body test</p>
<hr align:left >

<h3>Chapter 3.</h3>
<p> I recooment you to poass this time on the body test</p>
<hr align:center/>

<h3>Chapter 4.</h3>
<p> I recooment you to poass this time on the body test</p>
<hr align:right/>
</body>
</html>

Tuts

About Author

Tutsmaster.org provides tutorials related to tech and programmings. We are also setting up a community for the users and students.

You may also like

HTML introduction
Web Development

HTML – Introduction, History & Syntax

  • December 21, 2019
So, first of all, I would like to ask a question for the first time when you heard this term
html heading tag
Web Development

HTML – Heading Tag With Syntax

  • December 21, 2019
A heading tag is one of the most important tags we focus on in HTML or web development because, without