Margin contrasts how margins work differently for different types of boxes. It shows how margins change the position of an element in relation to its container and siblings.
Border contrasts how borders work differently for different types of boxes. It shows how borders change the position of an element in ways similar to margins, and in some ways different from margins.
Padding contrasts how padding works differently for different types of boxes. It shows how padding works almost identically to borders and margins.
Background shows how to assign a color to the background of an element. It also shows how to use a tiled image for the background. You can tile the image across and down, across only, or down only, or show the image only once. You can position the image at a specific location in the background. You can also direct whether the image scrolls with the content or remains in a fixed location.
You are currently reading a PREVIEW of this book.
Get instant access to over
$1 million worth of books and videos.