Comments on: Featured paper: Meta-stylesheets https://quoderat.megginson.com/2006/10/02/featured-paper-meta-stylesheets/ Open information and technology. Tue, 03 Oct 2006 08:06:06 +0000 hourly 1 http://wordpress.com/ By: Philip Fennell https://quoderat.megginson.com/2006/10/02/featured-paper-meta-stylesheets/#comment-504 Tue, 03 Oct 2006 08:06:06 +0000 http://www.megginson.com/blogs/quoderat/archives/2006/10/02/featured-paper-meta-stylesheets/#comment-504 It must be about three years ago that I had, what can only be described as, an epiphany with respect to seeing XSLT for what it is, an XML application and as such can be generated by XSLT and for that matter transformed by XSLT into another XSLT.

If you are using a framework like Apache’s Cocoon, that allows XSLT transforms to be referenced as the product of another pipeline then that’s one way to employ meta-stylesheets. Another and potentially more interesting approach, which I’m sure Mr. Kay will bring-up, is the use of the Saxon 8 / XSLT 2 extension functions saxon:compile-transform() and saxon:transform(). These two together allow you to load a stylesheet into your running stylesheet and apply it to a node-set or sequence that you are working on.

But why stop there when you could build a transform at run-time based on some aspect of your source document then apply that transform to either the source or some node-set derived from the source to produce the desired result.

All very wonderful stuff and I’d love to be there when he presents his paper but alas I will not. So I hope it will be available post conference.

I initially used XSLT transforms on XSLT stylesheets to map some XHTML generating XSLT into XSL-FO generating XSLT. The end result of that was to simplify the maintenance of a website that published to both XHTML and PDF. Structure and style changes to the XHTML where propagated to the PDF output automatically… Sweet 🙂

]]>
By: Forget It https://quoderat.megginson.com/2006/10/02/featured-paper-meta-stylesheets/#comment-503 Tue, 03 Oct 2006 07:39:21 +0000 http://www.megginson.com/blogs/quoderat/archives/2006/10/02/featured-paper-meta-stylesheets/#comment-503 Where is the paper?

All I see is an Abstract.

🙂

]]>