What are the differences between div and span tag?

 Posted by vishalneeraj-24503 on 10/8/2014 | Category: HTML 5 Interview questions | Views: 2135 | Points: 40

1). DIV considers as a container or area which generally is used for layout element or group of elements.
Whereas SPAN tags doesn't have own container or area,it is used just for formatting elements within SPAN block.
2). Div is a Container where we can place our data image, text or anything, and span is used for formatting.
3). Div tag is used as a paragraph break as it creates a logical division whereas Span tag does not.

Asked In: Many Interviews | Alert Moderator 

Comments or Responses

Login to post response