Chapter 3. Introducing Cascading Style Sheets

What you see on a web page when you use garden-variety HTML tags like <h1>, <p>, and <ul> pales in comparison to the text and styling on display in, say, a print magazine. If web designers had only HTML to make their sites look great, the Web would forever be the ugly duckling of the media world. HTML doesn’t hold a candle to the typographic and layout control you get when you create a document in even the most basic word processing program.

Fortunately for web designers, you can change the ho-hum appearance of HTML using a technology called Cascading Style Sheets (CSS). CSS gives you the tools you need to make HTML look beautiful. If you think of HTML as the basic structure of a house (the foundation, walls, and rooms), then CSS is the house’s interior decoration (the paint, carpeting, and the color, style, and placement of furniture). CSS gives you much greater control over the layout and design of your pages. Using it, you can add margins to paragraphs (just as in a word processor), colorful and stylish borders to images, and even dynamic rollover effects to text links. Dreamweaver’s streamlined approach to CSS makes it fast and easy to create styles and store them in a central style sheet that controls the look of all the pages in a site.

CSS is a big topic. It’s also the heart of today’s cutting-edge web design. So instead of dedicating just a single chapter to it, this book provides instruction in the fine art of using CSS in nearly ...

Get Dreamweaver CS6: The Missing Manual now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.