Wednesday 5 June 2013

Difference Between DIV and SPAN Tag in HTML

                 The difference between span and div is that a span element is in-line and usually used for a small chunk of HTML inside a line (such as inside a paragraph) whereas a div (division) element is block-line (which is basically equivalent to having a line-break before and after it) and used to group larger chunks of code.


<div id="scissors">
    <p>This is <span class="paper">crazy</span></p>

</div>

No comments:

Post a Comment