You are viewing a plain text version of this content. The canonical link for it is here.
Posted to taglibs-user@tomcat.apache.org by Shawn Bayern <ba...@essentially.net> on 2002/05/01 05:38:37 UTC
Re: JSTL XSLT question
On Tue, 30 Apr 2002, Brian J. Sletten wrote:
> Does anyone know how to use the document() function with the JSTL
> XML tags? Is it even possible?
>
> If I have two XML files in memory but need them both for a given
> transform, it would be nice to be able to merge them or somehow
> reference them both from within the XSL file.
Yes. We allow you to pass a system ID for the XSLT document for precisely
this purpose, using the xsltSystemId attribute for <x:transform>. The
system ID should be, in this case, a URL identifying the base page against
which the document() function's path should be resolved.
Thus, simply add an xsltSystemId attribute to your example:
<c:import url="/xml/summary.xsl" var="summaryXSL"/>
<x:transform xml="${summaryXML}" xslt="${summaryXSL}"
xsltSystemId="/xml/summary.xsl"/>
Note that the attributes you're using -- xmlText and xsltText -- are
outdated; the attributes since Beta2 are xml and xslt.
Hope that helps,
--
Shawn Bayern
"JSP Standard Tag Library" http://www.jstlbook.com
(coming this summer from Manning Publications)
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>