Paragraph Tag <p> Tag
HTML provides only limited paragraph formatting commands.
The most fundamental is the paragraph tag itself! Each paragraph
should begin with a start paragraph tag <p> and should end
with an end paragraph tag </p>.
should begin with a start paragraph tag <p> and should end
with an end paragraph tag </p>.
Open Text Editor and type.
<html>
<head>
<title> My First Web Page </title>
</head>
<body>
<H1>H1 Heading</H1>
<p>This is a paragraph</p>
<p>This is another paragraph</p>
</body>
</html>
<head>
<title> My First Web Page </title>
</head>
<body>
<H1>H1 Heading</H1>
<p>This is a paragraph</p>
<p>This is another paragraph</p>
</body>
</html>
Save the file as paragraph.html
Open file in browser(internet explorer, firefox )
Output
Output
Paragraph
This is a paragraph
This is another paragraph
HTML Line Breaks (<br>)
Use the <br/> tag if you want a line break (a new line) without starting a new
paragraph:
The <br/> element is an empty HTML element. It has no end tag.
paragraph:
The <br/> element is an empty HTML element. It has no end tag.
Open Text Editor and type.
<html>
<head>
<title> Break Line</title>
</head>
<body>
<H1> <br> Tag</H1>
<br/> This is<br/> a paragraph <br/> with line breaks<br/>
</body>
</html>
<head>
<title> Break Line</title>
</head>
<body>
<H1> <br> Tag</H1>
<br/> This is<br/> a paragraph <br/> with line breaks<br/>
</body>
</html>
Save the file as breakline.html
Open file in browser(internet explorer, firefox )Output
This is
a paragraph
with line breaks
a paragraph
with line breaks
powered by multimediagyan ©
No comments:
Post a Comment