Why is the

后端 未结 5 1014
太阳男子
太阳男子 2020-11-27 19:04

For curiosities sake, why is the <img> tag not closed in HTML?

\"Smiley

        
5条回答
  •  爱一瞬间的悲伤
    2020-11-27 19:09

    tag is basically a Void element.

    For your understanding:

    The image does not have any content. Image tag will just give the path from where the resource will be loaded through src attribute. So, it does not require any end element.

    Whereas Smiley face, this code is for XHTML version.

提交回复
热议问题