P {margin-top: -1em;} P {margin-top: 0;}<LINK REL="stylesheet" TYPE="text/css" HREF="link-styles.css"TITLE="Linked"><STYLE TYPE="text/css">@import url(import-styles.css);</STYLE>

Because Explorer will read in both style sheets, it will use thecascade to determine which rules should actually be applied. Ifyou've ordered things correctly, and the imported style sheetcomes after the linked style sheet, its rules will win out over the

Friday 15th of December 2017 08:50:09 PM

CSS Style Guide

XHTML Guidelines & Benefits

XHTML is the standard markup language for web documents and the successor to HTML 4. Library projects must be authored in structural XHTML 1.0 Transitional.

The following topics provide all the information you need to create well-formed XHTML pages that validate and are accessible, and/or to convert old HTML pages to valid, well-formed, accessible XHTML:

XHTML Guidelines
The rules of XHTML as compared to HTML — an easy transition
What is XML?
A brief introduction to the foundation of XHTML
XHTML Benefits
The benefits of converting from HTML to XHTML
XHTML Authoring Tips 'n Tools
Simplifying the work process—includes tips on using Dreamweaver
XHTML Accessibility Tips
Making sure your pages can be read
XHTML Validation
Keeping your markup kosher

Note that the boldface element in this case is positioned in relation to its parent element's content box, which defines its containing block. Without the relative positioning of the parent element, the containing block would be another element. Consider a case where the element being positioned is a child of the BODY element, e.g., a paragraph or heading element. With the right styles, the containing block for the positioned element will be the entire BODY element. Thus, applying the following styles to the BODY and the fifth paragraph in a document would

H2 {margin-left: 3em; margin-bottom: 2em; margin-right: 0; margin-top: 0;}

As we see in Figure 7-15, the margins were set as we wanted them.

Figure 7-15

Figure 7-15. More than one single-side margin

However, in this case, it might have been easier to use margin after all:

H2 {margin: 0 0 2em 3em;}

The results will be exactly the same as those we saw before, only10em. The reverse approach is also possible:

This will set the float to be 40em wide, unlessthat would be more than 40% the width of the containing block, inwhich case the float will be narrowed.

Of course, it's still possible to use these properties to keepan element from exceeding a certain size, as in this:

trick.)

11.2.9. Drop Caps With and Without :first-letter

Drop caps are avery common, and much-requested, typographical effect. A typical dropcap looks like the illustration in Figure 11-22.

Figure 11-22

Figure 11-22. A drop cap