SEARCH
  Tutorials HTML and CSS Articles Dreamweaver CS3 and Cascading Style Sheets

Dreamweaver CS3 and Cascading Style Sheets

Andrew Whiteman Articles May 18, 2009

Cascading Style Sheets (CSS) is a W3C standard mark-up language for defining the appearance of web pages. The use of CSS allows developers to fully separate the content of the page from its presentation, speeding up the development process and also making the pages load more quickly in the browser. Whereas 20th century websites typically used tables to construct web pages and position elements, CSS now provides a cleaner and more efficient way of controlling all aspects of web page layout.

The range of computer users who have some involvement in building web pages and web sites is vast and a good many of these users choose Dreamweaver as the software tool that helps them create the web content they need without needing to become an expert on underlying technologies such as CSS. Dreamweaver CS3 includes better support for Cascading Style Sheets than previous versions. However, there is still room for improvement.

Previous versions of Dreamweaver assumed that most users would be using tables to control the layout of their web pages. Dreamweaver CS3 is the first version of the program which encourages users to create CSS-based web page layouts. When the users create a new web page, they are offered a series of CSS layouts, on which they can base the new page, consisting of single, double and three column designs.

Instead of using tables to control positioning of web page content, CSS page layout makes extensive using of the DIV element an HTML construct which can contain just about anything, including other DIVs. The preset pages created by Dreamweaver CS3 contain a series of DIV element with the CSS code that controls their positioning. The placeholder text within the DIVs includes useful tips on customising the preset pages for your own use.

The CSS code for pages created using Dreamweaver's preset layouts is embedded in the page itself. If a user creates a series of such pages, each one will have its own CSS code making updating very time-consuming. It is far more efficient to have all of the CSS code in one external file and link each page to this one file. At present, Dreamweaver doesn't really make this clear to new users. However, it does have an excellent feature for moving embedded CSS code into an external file. You simply select all of the CSS definitions you wish to externalise then choose Text - CSS Styles - Move CSS Rules.

Although this ability to move CSS around is really great, it's not something that beginners will necessarily think of doing. It points to the fact that Dreamweaver could still do with a few enhancements to its implementation of CSS.

It is also disappointing that Dreamweaver still automatically generates CSS styles called "style1", etc. each time the user applies a font or colour to selected text. Surely it would be easier to simply remove these basic attributes and just let the user either apply a style to the selection or, if no styles exist, create a new one. Perhaps this will be introduced in the next release of this excellent program.

subscribe to newsletter