cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robin Green" <gree...@hotmail.com>
Subject Re: bug into the xsp-java.xsl
Date Fri, 12 Jan 2001 21:24:36 GMT
SoftLiban MOODAD Shadi <shadi.moodad@softsolutions.fr> wrote:
>When I tied to write the following code in an XSP file
>
>  
>document.appendChild(document.createProcessingInstruction("cocoon-process","type=\"xslt\""));
>
>  
>document.appendChild(document.createProcessingInstruction("xml-stylesheet","
>href=\"Magasin.fo.xsl\" type=\"text/xsl\" "));
>
>An error 'undefined variable document  and undefined xspCurrentNode' was
>returned as a result of the request of the specified file

This is a frequently asked question (not in the FAQ yet though). You have 
put your processing instruction code in the wrong place. This is NOT a bug, 
it is correct according to the documentation.

<xsp:page>
  Class-level variables and methods go here
   <your-page-tag>
      document generation goes here
   </your-page-tag>
</xsp:page>

It confuses a lot of people, so this will be made simpler in Cocoon 2.



_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.


Mime
View raw message