Today I’m discussing float. This feature in conjunction with earlier DIV tags can alter the inherent layout of a web page. This is the technique used in the earlier DIV post that rearranged the page.
The inherent layout is the normal top to bottom flow of a web page. Those elements appearing first in the code will be first on the web page. This is the normal flow of typed pages.
To float an element means to take it out of the normal flow and have it move up the page to the first available slot or open space. Also any elements below the floated element will move up and occupy the spot vacated by the moved floated element. If the slot is not large enough, then the floated element will not move up and will remain in it’s original position.
Click here to see diagrams of various float layouts. Notice the alternate format for the element style coding. It all works.
What people are saying