CSS:BoxModel

From mi-linux
Revision as of 13:42, 5 September 2007 by In6480 (talk | contribs)
Jump to navigationJump to search

The box model

When using CSS, every element can be thought of as an object with several different boundaries. The "content" is separated from the "border" by "padding", and the "border" is seperated from the next object by the "margin." Each of these boundaries are controllable through CSS. The picture below demonstrates the concept well:

The box model - from http://www.w3.org/TR/REC-CSS2/box.html