Full Stack Developer Masters Program (52 Blogs) Become a Certified Professional
AWS Global Infrastructure

Programming & Frameworks

Topics Covered
  • C Programming and Data Structures (41 Blogs)
  • Comprehensive Java Course (2 Blogs)
  • Java/J2EE and SOA (323 Blogs)
  • Spring Framework (8 Blogs)
SEE MORE

MI-new-launch

myMock Interview Service for Real Tech Jobs

myMock-widget-banner-bg

How to implement a Line Break Tag in HTML

Published on Aug 26,2019 16 Views

MI-new-launch

myMock Interview Service for Real Tech Jobs

myMock-mobile-banner-bg

myMock Interview Service for Real Tech Jobs

  • Mock interview in latest tech domains i.e JAVA, AI, DEVOPS,etc
  • Get interviewed by leading tech experts
  • Real time assessment report and video recording

Adding empty spaces and elements is one of the crucial things in HTML. <br> tag is one such example. Let’s start our journey of this break tag in HTML article in the following order:

 

What is Break Tag in HTML?

So basically when you use this <br/> tag, the content following it starts from the next line. This tag doesn’t need any opening or closing of the tags because there is nothing to be in between them. This <br/> tag represents a line break in an HTML document. Similarly <br/> tag is very helpful for writing poems and addresses.

HTML5 - HTML vs HTML5 - Edureka

This <br/> tag is used to insert the line break or the carriage-return within the parent element such as the paragraph without breaking out from the parent element. Unlike <p> tag defines the paragraph, an empty element is not added before this line.

 

Purpose of Break Tag

The <br/> tag main purpose is to use to give the line break in an HTML document. This <br/> element is classified as a “void element” because it has no content. This also means that there is no end tag for this one. After using this tag the sentence will be on the next different line. It’s little similar to the <p> tag.

 

Examples

Example 1:


<!DOCTYPE html>
<html>
		<head>
			<title> Line break in HTML </title>
		</head>
		<body>
			<p> Javascript<br/>
			You submitted your article on time.<br/>
			Good job<br/>
			Anantha</p>
		</body>
</html>

Output:

Break Tag in HTML

 

Example 2:


<!DOCTYPE html>
<html>
		<head>
			<title> Line break in HTML </title>
		</head>
		<body>
			<p> Python<br/>
			This has more scope<br/>
			in the current world<br/>
			Ananthapadmanabha</p>
		</body>
</html>

Output:

Example 2

 

With this, we come to an end of this article.

Check out our Full Stack Web Developer Masters Program which comes with instructor-led live training and real-life project experience. This training makes you proficient in skills to work with back-end and front-end web technologies. It includes training on Web Development, jQuery, Angular, NodeJS, ExpressJS, and MongoDB.

Got a question for us? Please mention it in the comments section of this blog and we will get back to you.

Comments
0 Comments

Browse Categories

webinar REGISTER FOR FREE WEBINAR
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP

Subscribe to our Newsletter, and get personalized recommendations.