Book HomeCascading Style Sheets: The Definitive GuideSearch this book Wednesday 23rd of April 2014 07:22:23 PM

Copyright © 2000 O'Reilly & Associates, Inc. All rights reserved.

Printed in the United States of America.

Published by O'Reilly & Associates, Inc., 1005 Gravenstein Highway North, Sebastopol, CA 95472.

Nutshell Handbook, the Nutshell Handbook logo, and the O'Reilly logo are registered trademarks of O'Reilly & Associates, Inc. Many of the designations used by manufacturers and sellers to distinguish their products are claimed as trademarks. Where those designations appear in this book, and O'Reilly & Associates, Inc. was aware of a trademark claim, the designations have been printed in caps or initial caps. The association between the image of a koala and the topic of HTML and XHTML is a trademark of O'Reilly & Associates, Inc.

While every precaution has been taken in the preparation of this book, the publisher assumes no responsibility for errors or omissions, or for damages resulting from the use of the information contained herein.



Library Navigation Links

Copyright © 2002 O'Reilly & Associates. All rights reserved.

A:link IMG {border-style: outset; color: silver;}

As Figure 7-32 shows, the border is now based on thelight gray silver, since that's now theforeground color of the image -- even though the imagedoesn't actually use that color, it's still passed on tothe border. We'll talk about another way to change bordercolors in a later section.

Figure 7-32

Figure 7-32. Changing the color of the border

four distinct properties to describe the offset of a positioned element's sides with respect to its containing block. These four properties, which we will refer to as the side-offset properties, are a big part of what makes positioning work.

These properties describe an offset from the nearest side of the containing block (thus the term side-offset ). For example, top describes how far the outer top edge of the positioned element should be placed from the top of itsH3 {border-bottom: 3px gray solid;}

Figure 7-47

Figure 7-47. Getting the same result in three different ways

You can also leave out some values and have their defaults kick in,like this:

H3 {color: gray; border-bottom: 3px solid;}

Since no border color is declared, the default value (theelement's foreground) is applied instead, as we can see inFigure 7-48. Just remember that if you leave out aborder style, the default value of none will