Skip to Main Content
CSS: The Missing Manual
book

CSS: The Missing Manual

by David Sawyer McFarland
August 2006
Beginner to intermediate content levelBeginner to intermediate
496 pages
17h 36m
English
O'Reilly Media, Inc.
Content preview from CSS: The Missing Manual

Understanding Style Sheets

Of course, a single style won't transform a Web page into a work of art. It may make your paragraphs red, but to infuse your Web sites with great design, you need many different styles. A collection of CSS styles comprises a style sheet. A style sheet can be one of two types— internal or external, depending on where the style information's located: in the Web page itself, or in a separate file linked to the Web page.

Internal or External—How to Choose

Most of the time, external style sheets are the way to go, since they make building Web pages easier and updating Web sites faster. They contain all your style information in a single file. With just a line of code, you attach the external style sheet to an HTML page and completely alter that page's appearance. You can revamp the look of an entire site by editing a single text file: the style sheet.

On the receiving end, external style sheets help Web pages open faster. When you use an external style sheet, your Web pages can contain only basic HTML—no byte-hogging HTML tables or <font> tags, and no internal CSS style code. Furthermore, when a Web browser downloads an external style sheet, it stores the file on your visitor's computer (in a behind-the-scenes folder called a cache) for quick access. When your visitor hops to other pages on the site that use the same external style sheet, there's no need for the browser to download the style sheet again. The browser simply pulls the external style sheet from ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

CSS: The Missing Manual, 2nd Edition

CSS: The Missing Manual, 2nd Edition

David Sawyer McFarland
JavaScript: The Missing Manual

JavaScript: The Missing Manual

David Sawyer McFarland

Publisher Resources

ISBN: 0596526873Supplemental ContentErrata Page