Re: How is this part of the XSLT specification to be interpreted?

Subject: Re: How is this part of the XSLT specification to be interpreted?
From: David Carlisle <davidc@xxxxxxxxx>
Date: Wed, 21 Jun 2000 11:13:14 +0100 (BST)
me> .... use <fallback/>....


<xxx xmlns="http://a/b/c";>
  <b a="2">
    <x:c xmlns:x="http:/x/y/z"/>

could be transformed to

<?xml version="1.0" encoding="utf-8" ?>
<x xmlns:y="http:/x/y/z">[xxx]</x>
<x:c xmlns:x="http:/x/y/z" xmlns="http://a/b/c"/>

by the stylesheet below.

It _is_ transformed to that using saxon.

xt and oraxsl (or at least the version I have, which may not be the latest)
don't support extension elements, so the documentation appears as
literal result elements in the output.

xalan (again, I'm not sure if this is the latest version) just dies
Xalan: was not successful.
XSLProcessor: done

But here is the stylesheet, it uses two elements in a documentation
namespace, one for documenting templates and one for documenting select
expressions. An XSLT stylesheet could easily take in this format and
pretty print the code below making for example the select expression be
an active link to its documentation.


<xsl:stylesheet xmlns:xsl="";

<xsl:output method="xml" indent="yes"/>

<xsl:template match="main:xxx">
 some doc about <emph>this</emph>  template
 <x>[<xsl:value-of select="name()"/>]</x>
 this select attribute selects grandchildren
 <xsl:apply-templates select="*/*"/>

<xsl:template match="y:c">
 some doc about <emph>this</emph> template, it matches 
 and copies c element nodes
 <xsl:copy-of select="."/>


Actually looking at it now in the mail buffer, perhaps it would have
been better to have put the xsl:copy expression _inside_ the fallback
rather than after the doc:select. Obviously the stylesheet that is
controlling the pretty printing basically controls what forms are

 XSL-List info and archive:

Current Thread