RE: XML pretty printing in HTML

Subject: RE: XML pretty printing in HTML
From: Kay Michael <Michael.Kay@xxxxxxx>
Date: Fri, 9 Jul 1999 15:41:41 +0100
> Here's a version of the above stylesheet (credits go to Jonathan Marsh
> at Microsoft for writing the original!) which runs cleanly in XT.
> A quick hack job to get it to run, but should get the
> thought process started...

Two oddities in this stylesheet.

(1) it attempts a match on the xml-declaration by treating it as a pi()
node. I don't think the xml-declaration is a processing instruction. (What's
more, it treats the things inside the xml-declaration as attributes! Elegant
perhaps, but correct? - no)

(2) it attempts a match on a cdata() node. I don't know what standard this
comes from and I'm surprised xt doesn't reject it.

There were a couple of features I had to change to make it work with SAXON:
both documented restrictions. One is that SAXON doesn't handle pi() and
comment() nodes, the other is that it doesn't handle wildcard name matches
of the form xml:* or xsl:*.

Mike Kay


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread