+ 1

Why <br /> element is an empty element and why it has no end tag?

26th Mar 2017, 10:52 AM
Jar Vis
Jar Vis - avatar
3 ответов
+ 9
@Andre: Not necessarily. The <p> and <li> need not be closed even though they contain content.
26th Mar 2017, 11:57 AM
Chirag Bhansali
Chirag Bhansali - avatar
+ 8
its purpose is to break a line. only elements that contain content need to be closed.
26th Mar 2017, 11:01 AM
Andre van Rensburg
Andre van Rensburg - avatar
0
<br/> just BReaks 'one' line It will work even if you don't close it...whereas "<br> </br>" in a HTML will break 2 lines. If you don't close <b> tag, then your rest of the webpage will contain bold text, but that doesn't happen in case of <br> as it represents only 1 line break, not multiple line breaks!
4th Dec 2017, 4:11 PM
friendly_nadim
friendly_nadim - avatar