cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jan Hoskens">
Subject Re: Jetty and XSLT with document()
Date Mon, 05 Jan 2004 14:15:40 GMT

You mean to use that in the sitemap? The document() is in the stylesheet so the cocoon protocols
do not apply there (or do they???). If I try to resolve the path in the sitemap, there has
to be a matching pipeline and the result will be a xml fragment. I tried to pass a documentpiece
as parameter (as a quick tryout) but that didn't seem to work. Is it possible to do that?
Passing a document fragment from the sitemap to the stylesheet?


  ----- Original Message ----- 
  From: Carmona Perez, David 
  Sent: Monday, January 05, 2004 3:02 PM
  Subject: RE: Jetty and XSLT with document()

  As a workaround to the problem, why don't try to use another protocol like:

    context:/myPath/myFile.xml or cocoon:/url





  -----Mensaje original-----
  De: Jan Hoskens []
  Enviado el: lunes, 05 de enero de 2004 14:53
  Asunto: Jetty and XSLT with document()




  I'm using a stylesheet with a variable that contains a nodeset variable:


  <xsl:variable name="Lookup" select="document('../resources/Lookup.xml')/Lookup"/>


  The path in the document() function is relative and does work under Tomcat.

  If I switch to jetty, an exception occurs when I want to use the variable as a nodeset:


  <xsl:if test="$Lookup/Item">


  FATAL_E (2004-01-05) 13:48.36:637   [core.xslt-processor] (/cocoontest/index.html) PoolThread-4/TraxErrorHandler:
Error in TraxTransformer: file:/d:/cocoontest/stylesheets/wdc2html.xsl; Line 101; Column 54;

  ; SystemID: file:/d:/cocoontest/stylesheets/wdc2html.xsl; Line#: 101; Column#: 54
  javax.xml.transform.TransformerException: java.lang.ClassCastException


  It seems that under Jetty, the variable does not contain the xml document at all and gives
an exception because the test expects a nodeset but does not receive one?


  Why doesn't Jetty give me the document as Tomcat does??

  Or is it wrong to use paths relative to the xsl document in the xsl itself?








View raw message