cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matthew Cordes <mcord...@maine.edu>
Subject Re: [C2]: Problem with logicsheet
Date Thu, 12 Apr 2001 21:34:59 GMT
Hi,

It was my understanding that to make use of logicsheets within a logicsheet
(e.g. esql inside of yours) you must include the namespace declaration 
in the original xml file. Also, you left it out, but I assume you have
a <?logicsheet href="..." ...?> directive.

-matt


On Thu, Apr 12, 2001 at 11:05:17PM +0200, Stefan Lettmayer wrote:
> Hi,
> 
> I hava a xml file with an <pmiutils:buttonbar /> tag, than the pmiutils logicsheet
applies some esql tags. But when I request the page in my browser i get either the page with
esql tags in it or i get an compile error in the cocoon.log:
> 
> org.apache.cocoon.components.language.LanguageException: Error compiling test_xm
> l:
> Line 0, column 0: /usr/local/java/apache/jakarta-tomcat-3.2.1/work/localhost_808
> 0%2Fpmi/org/apache/cocoon/www/xml/test_xml.java:3: Identifier expected.
> package ;
>        ^
> Line 0, column 0: /usr/local/java/apache/jakarta-tomcat-3.2.1/work/localhost_808
> 0%2Fpmi/org/apache/cocoon/www/xml/test_xml.java:33: Identifier expected.
> public class extends XSPGenerator {
>             ^
> 
> i have the following test.xml document:
> <xsp:page
> 	language="java"
> 	xmlns:xsp="http://apache.org/xsp"
> 	xmlns:pmiutils="http://www.pmi.at/2001/pmiutils"
> >
> 	<pmiutils:buttonbar />
> 	<page name="Startseite">
> 		<p>
> 			fshjfdhasjfhasdjfhas
> 		</p>
> 	</page>
> </xsp:page>
> 
> 
> this is my logicsheet:
> <xsl:stylesheet version="1.0"
> 	xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
> 	xmlns:xsp="http://apache.org/xsp"
> 	xmlns:esql="http://apache.org/cocoon/SQL/v2"
> 	xmlns:pmiutils="http://www.pmi.at/2001/pmiutils"
> >
> 
> 	<xsl:template match="pmiutils:buttonbar">
> 		<esql:connection>
> 			<esql:driver>org.postgresql.Driver</esql:driver>
> 			<esql:dburl>jdbc:postgresql://localhost/pmi_web</esql:dburl>
> 			<esql:username>pmi</esql:username>
> 			<esql:password>pmi</esql:password>
> 			<esql:execute-query>
> 				<esql:query>select * from test</esql:query>
> 				<esql:results>
> 					<esql:row-results>
> 						<h1><esql:get-string column="name"/></h1>
> 						<h2><esql:get-string column="content"/></h2>
> 						<esql:get-columns/>
> 					</esql:row-results>
> 				</esql:results>
> 			</esql:execute-query>
> 		</esql:connection>
> 	</xsl:template>
> 
> 	<xsl:template match="@*|*|text()|processing-instruction()">
> 		<xsl:copy>
> 			<xsl:apply-templates select="@*|*|text()|processing-instruction()"/>
> 		</xsl:copy>
> 	</xsl:template>
> 
> </xsl:stylesheet>
> 
> 
> This is the code fragment in the sitemap.xmap:
> <map:match pattern="plain/*.xml">
> 	<map:generate type="serverpages" src="xml/{1}.xml"/>
> 	<map:serialize type="html"/>
> </map:match>
> 
> 
> And this is the how i specify my logicsheet in the cocoon.xconf:
> <builtin-logicsheet>
> 	<parameter name="prefix" value="pmiutils"/>
> 	<parameter name="uri" value="http://www.pmi.at/2001/pmiutils"/>
> 	<parameter name="href" value="file:/usr/local/java/apache/jakarta-tomcat-3.2.1/pmiutils.xsl"/>
> </builtin-logicsheet>
> 
> 
> Thanks in advance
> 
> -- 
> Stefan Lettmayer
> Web: http://sharkman5.2y.net/
> ICQ: 67167870
> 
> ---------------------------------------------------------------------
> 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: <cocoon-users-unsubscribe@xml.apache.org>
> For additional commands, e-mail: <cocoon-users-help@xml.apache.org>
> 

---------------------------------------------------------------------
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: <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail: <cocoon-users-help@xml.apache.org>


Mime
View raw message