Creating Paragraphs and Line Breaks in HTML

Hi since you're new here, you may want to subscribe to our RSS feed to get convenient updates.. Thanks for visiting!

Let’s learn how to make paragraphs and text breaks in an HTML document. If you have a website, or want to build one, it’s essential to know this. No one wants to read a big block of text – so breaking up your text can make the difference between getting your information across versus losing visitors.

 

To make a paragraph, follow these instructions. If you would like, open up the file that you made in Introduction to HTML, and in the <body>, type this:
Hello, my name is Nick.</p><p>Welcome to my website!</p>

That text will come up in a web browser as:

Hello, my name is Nick.

Welcome to my website!

To make a line break, try this:
Hello, my name is Nick. <br>Welcome to my website!</br>
This will show up as:

Hello, my name is Nick.
Welcome to my website! Notice that the difference in the two styles is that with the paragraph <p></p> tags there is an extra line break. When you use the break tag <br></br> you start immediately on the next line.

Adding line breaks and paragraphs makes your document much better than it would otherwise. However, it is important to know when to use which. Generally, you will not want to use the <br></br> in the middle of paragraphs, instead you should save this tag for addresses and such. You also won’t want to use them for lists and the like.

Pretty soon, you can have a website that looks like a pro made it.

Press my buttons: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • bodytext
  • del.icio.us
  • Facebook
  • Google
  • Live
  • NewsVine
  • Reddit
  • Simpy
  • StumbleUpon
  • Technorati
  • TwitThis
  • Sphinn

|

Comment on this article/tutorial

You must be logged in to post a comment.