What is the use of tag in HTML?
What is the use of <br> tag in HTML?
In HTML, a tag is used to define various elements and their properties within a web page. Tags are enclosed in angle brackets (< >
) and come in pairs: an opening tag and a closing tag. The opening tag specifies the beginning of an element, and the closing tag (which often has a forward slash, like </tagname>
) marks the end of the element. Tags are fundamental for structuring and formatting content on a web page, such as defining headings (<h1>
to <h6>
), paragraphs (<p>
), links (<a>
), images (<img>
), lists (<ul>
, <ol>
, <li>
), and more. They provide the instructions that web browsers use to render the content correctly.
The <br> HTML element produces a line break in text (carriage-return). It is useful for writing a poem or an address, where the division of lines is significant.
- 14 Forums
- 1,837 Topics
- 5,053 Posts
- 0 Online
- 1,079 Members