Finally . . . the XML

After all this work, you can finally load the actual XML file. The script does this via a call to response.redirect at the very end. The target of the redirection can be an XML file or an ASP file. If you create a per-user style sheet, you should probably use an ASP file since you will have to create a link to the dynamically generated style sheet. See Listing 11.8 for an example article document encoded as an ASP file.

Listing 11.8. An XML Article Document Encoded in an ASP File
 <% Response.ContentType=”text/xml” %> <?xml version=”1.0”?> <?xml:stylesheet type=”text/xsl” href=”style<%= Request(“SCRIPT_NAME”) %>-<%= Session.SessionID %>”?> <article xmlns:xsl=”http://www.w3.org/1999/XSL/Transform”> <headline>Embedded Java ...

Get Special Edition Using XSLT 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.