XML technologies / XSLT / Java and XSLT / Introduction / Browser support for XSLT

(Excerpt from “Java und XSLT” by Eric M. Burke)

In a web application, client-side rather than server-side XSLT transformations can make sense for many reasons. Most importantly, they reduce server load and allow more simultaneous clients. Once a client downloads a stylesheet, later requests use a locally cached copy. Only the raw XML must then be retransmitted with each request, potentially reducing bandwidth substantially.

JavaScript permits even more interesting techniques. It can modify either the XML data or the XSLT stylesheet on the client, reapply the stylesheet, and display the result immediately without requesting the documents from the server again.

Microsoft introduced XSLT support in Internet Explorer 5.0 before the XSLT specification was finalized. Unfortunately, significant changes were made before it became a W3C recommendation, but Microsoft had already shipped IE with the older specification. Although Microsoft did a good job updating its MSXML parser for the final recommendation, millions of users will remain on IE 5.0 or 5.5 for a while, making portable client-side transformations difficult. Those users can download the MSXML parser separately from Microsoft. Once downloaded, installed and configured using xmlinst, the browser supports XSLT 1.0. Developers will probably do this, but few end users have the knowledge needed to follow these steps.

When this book was written, Netscape had not yet integrated XSLT into its browsers. Hopefully that will have changed by publication. Since Netscape’s implementation arrives much later than Microsoft’s, it should support the latest XSLT recommendation.

Browser plug-ins supporting XSLT are another option, probably most effective within a company. There, the browser can be controlled to some extent, making client-side transformations more feasible than on public websites.

Browser compatibility problems will make client-side XSLT messy for years, so Java’s role in XSLT will grow. A Java servlet could detect the browser and send the appropriate stylesheet, or start the transformation using a server-side XSLT processor. After the next two chapters introduce XSLT syntax, the rest of this book discusses Java and XSLT.

   

 

 

 

back to top