Blocks in Html

In this chapter we about the blocks, in html page block elements are started from new line or before a line and after a line block level element is shown.

Most probably there is two type of block level elements used in html:

  1. Div
  2. Span

Div starts from the new line or we say that it occupies all the space on the screen.

Div is Block level element.

While Span is start from same line it cannot occupy all space it only occupy space that content have.

Span is inline element.