O'Reilly logo

Effective XML: 50 Specific Ways to Improve Your XML by Elliotte Rusty Harold

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

Item 44. Serve XML+CSS to the Client

Given the limitations of the installed base of browsers, I'm not sure I would ever recommend serving XML directly rather than transforming on the server side. However, most current desktop web browsers do have reasonable support for direct display of XML documents with attached CSS stylesheets. The exact part of CSS any browser supports varies from one to the next, but browsers that include some reasonable level of CSS support include Internet Explorer 5.0 and later, Opera 4.0 and later, Netscape 6.0 and later, Mozilla, Safari, and Konqueror. Support for CSS is much better on the client side than support for XSLT. If you really want to serve XML documents directly to clients, CSS is the way to go.

Unlike ...

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