Saturday 19th of May 2012 05:29:17 PM
by Eric A. Meyer
ISBN 1-56592-622-6
First edition, published May 2000.
(See the catalog page for this book.)
Search the text of Cascading Style Sheets: The Definitive Guide.
Web-safe colors are those colors that are expressed in multiples ofthe RGB values 20% and 51, andthe corresponding hex-pair value 33. Also,0% or 0 is a safe value. So, ifyou use RGB percentages, then make all three values either0% or a number divisible by 20; for example,rgb(40%,100%,80%) or Colophon
Copyright © 2002 O'Reilly & Associates. All rights reserved.
Now let us consider the cases where two of these three properties are set to auto. If both the margins are set to auto, then they are set to equal lengths, thus centering the element within its parent, as you can see from Figure 8-14:
P {width: 100px; margin-left: auto; margin-right: auto;}

This is the correct way to center block-level elements, as a matter
There is one other importantaspect of vertical formatting, which is the collapsing of adjacentmargins. This comes into play when an element with declared marginsimmediately follows another such element in the document'slayout. This was discussed in the previous chapter, using thisexample:
LI {margin-top: 10px; margin-bottom: 20px;}