cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Laurent Eskenazi" <lesken...@mail.inforama.fr>
Subject Custom taglib problem
Date Thu, 03 Aug 2000 16:01:48 GMT
Hi !

I'm trying to make a very simple custom taglib, but I'm getting an error
with cocoon 1.7.4 :

Java.lang.NullPointerException
                          at
org.apache.cocoon.processor.xsp.XSPProcessor.process(Compiled Code)
                          at org.apache.cocoon.Engine.handle(Compiled Code)
                          at org.apache.cocoon.Cocoon.service(Compiled Code)
                          at javax.servlet.http.HttpServlet.service(Compiled
Code)
                          at
org.apache.jserv.JServConnection.processRequest(Compiled Code)
                          at org.apache.jserv.JServConnection.run(Compiled
Code)
                          at java.lang.Thread.run(Compiled Code)



* Here is my XSP File:
<?xml version="1.0" encoding="ISO-8859-1"?>

<?cocoon-process type="xsp"?>

<xsp:page
  language="java"
  xmlns:atl="http://www.apache.org/1999/ATL"
  xmlns:xsp="http://www.apache.org/1999/XSP/Core"
>

  <page>
    <title>Welcome to AntiStatic.org's Taglib test page !</title>
    <p>Il est maintenant <atl:heure/>.</p>
  </page>

</xsp:page>



* Here is my Taglib file:
<?xml version="1.0" encoding="iso-8859-1"?>

<xsl:stylesheet version="1.0"
 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
 xmlns:xsp="http://www.apache.org/1999/XSP/Core"
 xmlns:atl="http://www.apache.org/1999/ATL"
>

  <xsl:template match="atl:heure">
    <xsp:logic>
      Date date = new Date();
    </xsp:logic>

<xsp:expr>date.getHours()</xsp:expr>:<xsp:expr>date.getMinutes()</xsp:expr>
  </xsl:template>

</xsl:stylesheet>



* And in cocoon.properties:
processor.xsp.logicsheet.context.java  =
resource://org/apache/cocoon/processor/xsp/library/java/context.xsl
processor.xsp.logicsheet.cookie.java   =
resource://org/apache/cocoon/processor/xsp/library/java/cookie.xsl
processor.xsp.logicsheet.global.java   =
resource://org/apache/cocoon/processor/xsp/library/java/global.xsl
processor.xsp.logicsheet.request.java  =
resource://org/apache/cocoon/processor/xsp/library/java/request.xsl
processor.xsp.logicsheet.response.java =
resource://org/apache/cocoon/processor/xsp/library/java/response.xsl
processor.xsp.logicsheet.session.java  =
resource://org/apache/cocoon/processor/xsp/library/java/session.xsl
processor.xsp.logicsheet.util.java     =
resource://org/apache/cocoon/processor/xsp/library/java/util.xsl
processor.xsp.logicsheet.sql.java      =
resource://org/apache/cocoon/processor/xsp/library/java/sql.xsl

processor.xsp.logicsheet.atl.java      =
file://home/laurent/atl-test-lib.xsl


How can I manage to make this work ?

Thanks

Laurent


Mime
View raw message