What is the difference between HTML tags
and ?

后端 未结 13 1437
时光取名叫无心
时光取名叫无心 2020-11-22 05:48

I would like to ask for some simple examples showing the uses of

and . I\'ve seen them both used to mark a section of a pa
13条回答
  •  生来不讨喜
    2020-11-22 06:21

    The significance of "block element" is implied but never stated explicitly. If we ignore all the theory (theory is good) then the following is a pragmatic comparison. The following:

    This paragraph has a span.

    This paragraph

    has
    a div.

    produces:

    This paragraph has a span.
    
    This paragraph
    
    has
    a div.
    

    That shows that not only should a div not be used inline, it simply won't produce the desired affect.

提交回复
热议问题