You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Ken Helmes <Ke...@codeonline.com> on 2000/09/26 15:55:05 UTC

Custom tag libraries

Access to the mailing archives seems to be down, so I can't check if this
question has been asked.

I am using cocoon with Tomcat and Apache.
XSP works fine when I embed Java in a page, but it seems to ignore any
custom xsp tag libraries.  I have:
- used an example.xsl, sample.xsl, skeleton.xsl from
http://www.plenix.com/xsp/doc/xsp-primer.html (and tried the Java and XML
book example as well)
- created a logicsheets.jar file with the example.xsl sheet
- edited cocoon.properties to support the new example tag libary
- edited the Tomcat batch file to support the new example tag library

The text is output correctly but the custom tags are not read.  I have spent
several hours on this trying different configurations, xsl sheets, etc.  Any
help is appreciated.  Any ideas?

Regards,

Ken Helmes
Software Engineer
CODEONLINE, Ltd.
Ukonvaaja 2A
02130 Espoo
Finland


Re: Custom tag libraries

Posted by sudhi <su...@insage.com>.
Hi Ken,
Got it working. This is xml output, since I dont have the xsl I
commented out the xslt part, just left with xsp.

-------------------------------------
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"
"http://www.w3.org/TR/REC-html40/strict.dtd">
<user>
  <title>Title</title>

  <test>
        26-21-00
        <foo></foo>Ken Helmes<bar></bar>
 </test>
</user>

<!-- This page was served in 3773 milliseconds by Cocoon 1.7.4 -->
--------------------------------------

These are the things I did with ur xsl.

1. Since I dont have com.codeonline.Data I removed <xsp:include> tag for
this class.
2. On line 43 u have 

            <xsl:with-param name="content" select="util:format"/>

and it should be

             <xsl:with-param name="content" select="datax:format"/>

Once I changed this, created a jar file, added that jar file in my
jserv.properties wrapper.classpath.
Added this line to cocoon.properties (by the way i stored ur taglib as
data.xsl)

processor.xsp.logicsheet.datax.java  = resource://data.xsl

And it worked.
HTH
Sudhi




Ken Helmes wrote:
> 
> It's very short.  The tag is of course datax in this file:
> 
> <?xml version="1.0"?>
> 
> <!-- Author: Ken Helmes "Ken.Helmes@codeonline.com" -->
> <!-- Version: Id: addUser.xml,v 1.0 2000/09/14  -->
> 
> <?cocoon-process type="xsp"?>
> <?cocoon-process type="xslt"?>
> <?xml-stylesheet href="addUser-html.xsl" type="text/xsl"?>
> <xsp:page
>   language="java"
>   xmlns:xsp="http://www.apache.org/1999/XSP/Core"
>   xmlns:datax="http://www.codeonline.com/coffee/data/"
> >
> 
> <user>
>   <title>Title</title>
> 
>   <test>
>         <datax:time format="dd-mm-yy"/>
>         <datax:addUser user="test"/>
>  </test>
> </user>
> 
> </xsp:page>
> 
> -----Original Message-----
> From: sudhi [mailto:sudheendra@insage.com]
> Sent: Tuesday, September 26, 2000 5:00 PM
> To: cocoon-users@xml.apache.org
> Subject: Re: Custom tag libraries
> 
> Hi,
> whats ur xml files looks like ?
> Do u have those namespaces in ur xml ?
> ~S
> 
> Ken Helmes wrote:
> >
> > Access to the mailing archives seems to be down, so I can't check if this
> > question has been asked.
> >
> > I am using cocoon with Tomcat and Apache.
> > XSP works fine when I embed Java in a page, but it seems to ignore any
> > custom xsp tag libraries.  I have:
> > - used an example.xsl, sample.xsl, skeleton.xsl from
> > http://www.plenix.com/xsp/doc/xsp-primer.html (and tried the Java and XML
> > book example as well)
> > - created a logicsheets.jar file with the example.xsl sheet
> > - edited cocoon.properties to support the new example tag libary
> > - edited the Tomcat batch file to support the new example tag library
> >
> > The text is output correctly but the custom tags are not read.  I have
> spent
> > several hours on this trying different configurations, xsl sheets, etc.
> Any
> > help is appreciated.  Any ideas?
> >
> > Regards,
> >
> > Ken Helmes
> > Software Engineer
> > CODEONLINE, Ltd.
> > Ukonvaaja 2A
> > 02130 Espoo
> > Finland
> >
> >   ------------------------------------------------------------------------
> >
> >    ATT21493.txtName: ATT21493.txt
> >                Type: Plain Text (text/plain)
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: cocoon-users-help@xml.apache.org
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: cocoon-users-help@xml.apache.org

Re: Custom tag libraries

Posted by sudhi <su...@insage.com>.
Can u send me those taglib ?

sudhi wrote:
> 
> Hi,
> Check the java file in the repository , and see whether these tags
> 
> <datax:time format="dd-mm-yy"/>
> <datax:addUser user="test"/>
> 
> are replaced or not.
> ~S
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: cocoon-users-help@xml.apache.org

Re: Custom tag libraries

Posted by sudhi <su...@insage.com>.
Hi,
Check the java file in the repository , and see whether these tags

<datax:time format="dd-mm-yy"/>
<datax:addUser user="test"/>

are replaced or not.
~S

RE: Custom tag libraries

Posted by Ken Helmes <Ke...@codeonline.com>.
It's very short.  The tag is of course datax in this file:

<?xml version="1.0"?>

<!-- Author: Ken Helmes "Ken.Helmes@codeonline.com" -->
<!-- Version: Id: addUser.xml,v 1.0 2000/09/14  -->

<?cocoon-process type="xsp"?>
<?cocoon-process type="xslt"?>
<?xml-stylesheet href="addUser-html.xsl" type="text/xsl"?>
<xsp:page
  language="java"
  xmlns:xsp="http://www.apache.org/1999/XSP/Core"
  xmlns:datax="http://www.codeonline.com/coffee/data/"
>

<user>
  <title>Title</title>

  <test>
	<datax:time format="dd-mm-yy"/>
	<datax:addUser user="test"/>
 </test>
</user>

</xsp:page>

-----Original Message-----
From: sudhi [mailto:sudheendra@insage.com]
Sent: Tuesday, September 26, 2000 5:00 PM
To: cocoon-users@xml.apache.org
Subject: Re: Custom tag libraries


Hi,
whats ur xml files looks like ?
Do u have those namespaces in ur xml ?
~S


Ken Helmes wrote:
>
> Access to the mailing archives seems to be down, so I can't check if this
> question has been asked.
>
> I am using cocoon with Tomcat and Apache.
> XSP works fine when I embed Java in a page, but it seems to ignore any
> custom xsp tag libraries.  I have:
> - used an example.xsl, sample.xsl, skeleton.xsl from
> http://www.plenix.com/xsp/doc/xsp-primer.html (and tried the Java and XML
> book example as well)
> - created a logicsheets.jar file with the example.xsl sheet
> - edited cocoon.properties to support the new example tag libary
> - edited the Tomcat batch file to support the new example tag library
>
> The text is output correctly but the custom tags are not read.  I have
spent
> several hours on this trying different configurations, xsl sheets, etc.
Any
> help is appreciated.  Any ideas?
>
> Regards,
>
> Ken Helmes
> Software Engineer
> CODEONLINE, Ltd.
> Ukonvaaja 2A
> 02130 Espoo
> Finland
>
>   ------------------------------------------------------------------------
>
>    ATT21493.txtName: ATT21493.txt
>                Type: Plain Text (text/plain)

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-users-help@xml.apache.org



Re: Custom tag libraries

Posted by sudhi <su...@insage.com>.
Hi,
whats ur xml files looks like ?
Do u have those namespaces in ur xml ?
~S


Ken Helmes wrote:
> 
> Access to the mailing archives seems to be down, so I can't check if this
> question has been asked.
> 
> I am using cocoon with Tomcat and Apache.
> XSP works fine when I embed Java in a page, but it seems to ignore any
> custom xsp tag libraries.  I have:
> - used an example.xsl, sample.xsl, skeleton.xsl from
> http://www.plenix.com/xsp/doc/xsp-primer.html (and tried the Java and XML
> book example as well)
> - created a logicsheets.jar file with the example.xsl sheet
> - edited cocoon.properties to support the new example tag libary
> - edited the Tomcat batch file to support the new example tag library
> 
> The text is output correctly but the custom tags are not read.  I have spent
> several hours on this trying different configurations, xsl sheets, etc.  Any
> help is appreciated.  Any ideas?
> 
> Regards,
> 
> Ken Helmes
> Software Engineer
> CODEONLINE, Ltd.
> Ukonvaaja 2A
> 02130 Espoo
> Finland
> 
>   ------------------------------------------------------------------------
> 
>    ATT21493.txtName: ATT21493.txt
>                Type: Plain Text (text/plain)