Sunday, February 04, 2007

CSS – A Way to Design and Manage Web Pages

I got a Christmas present this year that keeps on giving—“CSS The Missing Manual” by David Sawyer McFarland. It’s for the beginner and it’s well done, understandable, easy to read and contains workable design suggestions. I just completed it and have applied the concepts on several projects. Here’s some background.

Browsers present the sights and sounds of the World Wide Web on your computer. You are probably using Microsoft’s Internet Explorer, Netscape, Opera, Safari or Mozilla’s Firefox. You instruct a browser to display your web page by sending it a set of HTML-related instructions. These instructions can be manually composed or can be composed by WYSIWYG applications. These applications make the task easier and more intuitive. Examples are Microsoft’s FrontPage and Adobe’s Dreamweaver.

Traditionally, all of the content (text, data and images) and the appearance (fonts, colors, placements, etc.) was coded into the HTML. Content and the control of appearance are separated when using CSS. Good practice dictates that the HTML contain only the content and than the CSS controls the appearance of the web page. There are compelling reasons for doing this:

A change in style, e.g. changing a color or font, involves changes in specific areas of the CSS. Otherwise, each item affected would need to be found and changed in the HTML.
Web pages designed for one browser can look different, sometimes disturbingly, in other browsers. Since this is a matter of appearance, style sheets can be composed and called upon for particular browsers. This is one method of rendering the appearance of a web page the same in various browsers.

Most people prefer using WYSIWYG methods of designing web pages. WordPress and XStandard are examples of WYSIWYG applications that use the HTML and CSS method for the design. Once a page is designed by one of these editors, style sheets can easily be edited or added to make overall style changes or to make adaptations for various browsers.

If you’re interested in this concept, I recommend the book.

Technorati Tags:, , ,

No comments: