You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Scott Jones <sc...@on-sitemanager.com> on 2001/10/12 20:57:53 UTC

[C2] Logicsheets not processing?

Hello,

I'm in the midst of revamping the section of our site that uses C1.8 to
use C2, and I'm having trouble getting logicsheets working.  So, I've
been trying to get a very simple example running.

The xsp within my page processes, the calls to the logicsheet are
removed, and then the transform happens...  It's as if the calls to the
logicsheet weren't even there.

Does anyone have any suggestions for me?

Thank you!!

-Scott



My file is sitting in {TOMCAT_HOME}/webapps/ROOT/XML/content/test.xml

<?xml version="1.0" encoding="ISO-8859-1"?>
<xsp:page
          language="java"
          xmlns:xsp="http://apache.org/xsp"
	  xmlns:test="http://www.on-sitemanager.com/test"
>
  <page>
    <test:hello/>
    <paragraph>hi there</paragraph>
    <xsp:expr> (1+1)</xsp:expr>
  </page>
</xsp:page>

============================================================

My logicsheet is in
{TOMCAT_HOME}/webapps/ROOT/XML/logicsheets/test-xsp.xsl

<?xml version="1.0"?>
<xsl:stylesheet
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  xmlns:xsp="http://apache.org/xsp"
  xmlns:test="http://www.on-sitemanager.com/test"
  version="1.0"
>
  <xsl:template match="test:hello">
    <xsp:expr>new String("hello")</xsp:expr>
  </xsl:template>

  <xsl:template match="@*|node()" priority="-1">
    <xsl:copy>
      <xsl:apply-templates select="@*|node()"/>
    </xsl:copy>
  </xsl:template>

</xsl:stylesheet>

===========================================================

I've registered the logicsheet in WEB-INF/cocoon.xconf

<builtin-logicsheet>
  <parameter name="prefix" value="test"/>
  <parameter name="uri" value="http://www.on-sitemanager.com/test"/>
  <parameter name="href"
	value="file:///usr/local/tomcat-scott/webapps/ROOT/XML/logicsheets/test-xsp.xsl"/>
</builtin-logicsheet>

==========================================================

And my sitemap has an entry like this:

 <map:match pattern="forms/*.html">
   <map:generate type="serverpages" src="XML/content/{1}.xml"/>
   <map:transform src="XML/stylesheets/form-html.xsl"/>
   <map:serialize/>
 </map:match>



---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <co...@xml.apache.org>
For additional commands, e-mail: <co...@xml.apache.org>