HTML Paragraph

HTML paragraph or HTML p tag is used to define a paragraph in a web page.  If we are using various <p> tags in one HTML page then browser automatically adds a single blank line between the two paragraphs.

HTML p tag removes extra space and extra line inside HTML Paragraph while displaying the page.

 

An HTML <p> Element

HTML element <p> is used to define a paragraph. A paragraph always starts on a new line.

Syntax :

<p>This is first paragraph.</p>
<p>This is second paragraph.</p>
<p>This is third paragraph.</p>

An HTML <br> Element

The HTML <br> element defines a line break.

The HTML <br> tag is used to add line break (a new line) without starting a new paragraph.

Syntax :

<p>This is text paragraph.<br /> This is line break tag</p>

An HTML <hr> Element

An HTML <hr> tag is used to apply a horizontal line between two statements or two paragraphs.

Syntax :

<p>This is text paragraph. <hr /> This is add horizontal line with paragraphs</p>

 

Example :

<!DOCTYPE html>
<html>
<head>
<title>Learn HTML Paragraph <p>tag by aryatechno</title>
</head>
<body>
<table>
<tr>
<td>
<p>Learn html paragraph tag.</p>
<p>Aryatechno provides html paragraph tutorials.<hr/></p>
<p>Learn break line and horizontal line with paragraphs <br/> Lets see example for html paragraph tag.</p>
</td>
</tr>
</table>
</body>
</html>

Output :

Comments

Leave a Reply

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

55024