O'Reilly logo

Practical Web Technologies by V. Lau, P. K. Yuen

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

5.4. Using CSS and parser on XML documents

5.4.1. Using CSS on XML pages

CSS is considered to be an integral part of all HTML/XHTML documents and used on almost every serious page on the Web. By separating the formatting properties such as color, font, size, background, and border from the markup contents, CSS provides a structural base for all HTML/XHTML documents.

One of the interesting features of CSS is that it can be used to redefine the formatting properties of an HTML/XHTML tag. Consider the following example:

Example. ex05–18.htm – Redefine Formatting Properties Using CSS
 1: <?xml version="1.0" encoding="UTF-8"?> 2: <!DOCTYPE html 3: PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 4: "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required