0
Although the <br> tag is go to the next line..
Why its called as a inline element not block?
1 Respuesta
+ 3
sid <br> tag doesn't go to the next line. <br> tag just break to the new line.
Block elements always start from new line but inline elements can be write in same line. For example div tag is block element and span is inline element. So we write
<div>
<span></span><span></span><br><br>
</div>
Here I have written br tag with span tag so br tag is also a inline element.
But you can't write block elements with inline elements. For example
<div></div><span></span><br> //this will be wrong
You can write inline elements inside block elements. But as br tag is not block element so you can't write inline element in br tag. For example:
<br><span></span><br> it would be wrong Because here br tag doesn't have closing block.