|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] document() function...
I tried to use the document function. I started with an example from the book
"XSLT Reference" by Michael Kay.
Here the stylesheet:
<xsl:transform
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0"
>
<xsl:template match="/">
<html><body>
<h1>Stylesheet Module Structure</h1>
<ul>
<xsl:apply-templates select="*/xsl:include | */xsl:import"/>
</ul>
</body></html>
</xsl:template>
<xsl:template match="xsl:include | xsl:import">
<li><xsl:value-of select="concat(local-name(),'s ',@href)"/>
<xsl:variable name="module" select="document(@href)"/>
<ul>
<xsl:apply-templates select="$module/*/xsl:include | $module/*/xsl:import"/>
</ul>
</li>
</xsl:template>
</xsl:transform>
And here the contents:
<xsl:transform
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0"
>
<xsl:include href="dummya.xsl"/>
</xsl:transform>
When I try to merge this two files into an HTML file using James Clarks XT, I
get a MalFormedURLException telling that I have not defined a protocol.
According to the spec it should be valid to provide a relative URI (hr
ef="dummya.xsl").
I could only make this work using an absolute URI and using the http protocol
(href="http://winkelried:9992/Data/E2/htmlconverter/3129/ch07/dummya.xsl").
Does anyone no if this is a bug in James Clarkes XT. Do I miss something here?
Thanks
Martin
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








