Hi.

> 1. Load the XML document from a specific URL
> 2. Load the XSL document from a specific URL
> 3. Add runtime parameters to the transformation
> 4. Do the transformation.

> In the examples I've seen 1,2 and 4 done, but not 3.
> Is it at all possible? Or is this for a future version
> of the library?

You should use the <x:param> tag describe in section 13.3 of the final spec.

<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core"; %>
<%@ taglib prefix="x" uri="http://java.sun.com/jstl/xml"; %>

<c:set var="xsl">
  <?xml version="1.0"?>
  <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; version="1.0">

  <xsl:param name="bar" select="'Default value.'"/>
  
  <xsl:template match="foo">
    <html><body><xsl:apply-templates/></body></html>
  </xsl:template>

  <xsl:template match="name">
    <h1><xsl:apply-templates/> <xsl:copy-of select="$bar"/></h1>
  </xsl:template>

  </xsl:stylesheet>
</c:set>


<x:transform xslt="${xsl}">
<foo>
    <name>Foo</name>
</foo>
<x:param name="bar" value="foobar"/>
</x:transform>


/Lars, 
Itera Consulting Group Denmark

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to