Use block-level elements to break the line without using <br> tag. There are many ways to break the line without using <br> tag.
The used properties are listed below:
- white-space: pre; It is used to make elements acts like <pre> tag.
- display: block; It sets the display property of elements to block.
Example 1: This example uses white-space to pre to break the line.
Example 2: This example uses display property to break the line.
- How to define a possible line-break using HTML5 ?
- How to insert line break before an element using CSS?
- What is the difference between “word-break: break-all” versus “word-wrap: break-word” in CSS ?
- How to make a vertical line using HTML ?
- How to add line breaks to an HTML textarea?
- How to read a file line by line using node.js ?
- Break and Next statements in R
- CSS | word-break Property
- CSS | box decoration break Property
- CSS | page-break-after Property
- How to break an outer loop with PHP ?
- Difference between break and continue in PHP
- CSS page-break-before Property
- How to prevent column break within an element?
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to firstname.lastname@example.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.