Using XSL and CSS Together

I've already mentioned that XSL and CSS are not bitter rivals, and that they can actually be used together. In fact, the current state of browser support for XSL almost requires a hybrid approach involving both technologies. The following are three ways in which XSL and CSS can be used together to provide a hybrid XML style sheet solution:

  • Use XSL on the server to transform XML documents into HTML documents that are styled with CSS style sheets.

  • Use XSL on the server to transform XML documents into XML documents that are styled with CSS style sheets.

  • Use XSL on the client to transform XML documents into HTML documents that are styled with CSS style sheets.

Just in case you couldn't tell, these approaches to using XSL ...

Get XML Unleashed 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.