kenworld
CSS Cookbook


CSS Cookbook
By: Christopher Schmitt
Published: 2004
Reviewed: 3/10/2006



The "CSS Cookbook" is a companion book to another O'Reilly Media publication called "Cascading Style Sheets: The Definitive Guide". The cookbook assumes you have already read a book on Cascading Style Sheets and have some experience. Without background material a novice would get lost. I read "Cascading Style Sheets: Separating Content from Presentation" back in 2002 but any book on CSS should do. The "CSS Cookbook" consists of a series problems in the form "I want to do X". For each problem the author presents a solution to X followed by a discussion on why the solution works and possible variations. Sometimes the discussion mentions compatibility issues with different browsers. I often found this disheartening, because CSS support for older browsers is really messed up and even current versions do not fully support the standard. For example Internet Explorer does not support ":before" and ":after" pseudo-elements. [These are particularly useful for adding graphics around content].

The software publishing world seems to be giving up the idea that their books last for very long. Many of the problems have a "See Also" section that is filled with URLs to sites the author and/or publisher have absolutely no control over. Hence some of them may already be dead. Personally I have only used CSS on my web site to give headings a consistent relative size and to provide some paragraph indenting options. I did get a few ideas from the "CSS Cookbook" for future revisions. Of course, content is always more valuable than presentation.