[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

RE: [xsl] Issue with document('') under Xalan-Java


Subject: RE: [xsl] Issue with document('') under Xalan-Java
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Tue, 19 Jan 2010 09:11:11 -0000

> I am creating an XSL transformer like this:
> 
> TransformerFactory transformerFactory = TransformerFactory
>                 .newInstance();
> transformerFactory.setAttribute("indent-number", new 
> Integer(2)); Transformer trans = 
> transformerFactory.newTransformer(sheetSource);
> 
> And in my document I have something like this:
> 
> 
> <xsl:variable name="langs-top" 
> select="document('')/*/l:languagecodes"/>
> 
> 

The most likely explanation is that sheetSource is a StreamSource with no
systemId set. The systemId determines the base URI of the stylesheet, and
without knowing a base URI, document('') doesn't know where to look.

Regards,

Michael Kay
http://www.saxonica.com/
http://twitter.com/michaelhkay 


Current Thread
Keywords
xsl