Nathaniel Alfred wrote:
-----Original Message-----
From: Lars Huttar [mailto:[EMAIL PROTECTED]
Sent: Montag, 8. August 2005 19:21
To: [email protected]
Subject: Re: esql logicsheet sometimes fails to transform elements
If that is the case, try to refer to your logicsheet inside the XSP by
<xsp:logicsheet location="path/to/sil.xsl"/>.
OK, I tried this. The first try, I made <xsp:logicsheet
location="resource://logicsheets/sil.xsl"/> the child of the
<xsp:page>
element, before the other child element. The result was a
ProcessingException: java.net.MalformedURLException: Invalid System ID
at
org.apache.cocoon.generation.ServerPagesGenerator.setup(ServerP
agesGenerator.java:176)
...
Caused by: java.net.MalformedURLException: Invalid System ID
at
org.apache.excalibur.source.impl.SourceResolverImpl.resolveURI(
SourceResolverImpl.java:168)
Does this have something to do with the resource:// pseudo-protocol? If
so, what can I do about it? It would be impractical to have to use an
absolute file:// URL in our XSP pages, because Cocoon is installed in
different places on different machines. Just to see if this was the
issue, I tried <xsp:logicsheet location="file:///D|/...absolute.path.../logicsheets/sil.xsl"/> and
<xsp:logicsheet location="file:///D:/...absolute.path.../logicsheets/sil.xsl"/>
, but got the same exception.
I also tried moving <xsp:logicsheet location="resource://logicsheets/sil.xsl"/> to be the
grandchild of the
<xsp:page> element, and child of the <page> element. The behavior
returned to what it had been, namely, outputting <esql:*> tags instead
of querying the database.
Any more information on how to use <xsp:logicsheet/> would be
appreciated.
Thanks,
Lars
xsp:logicsheet must be a child of xsp:page. For relative locations you can use
one of these protocols:
location="path/to/sil.xsl" (relative to current sitemap)
location="cocoon://path/to/sil.xsl" (relative to root sitemap)
location="context://path/to/sil.xsl" (relative to webapp directory)
NB the xsp:logicsheet magic happens in
o.a.c.components.language.markup.CocoonMarkupLanguage.
Cheers, Alfed.
Thanks for the further pointers! These work for me, and appear to have
fixed the problem.
It would be very helpful to see these things documented in the
"Logicsheets Using Logicsheets" section of
http://cocoon.apache.org/2.1/userdocs/xsp/logicsheet.html
I would be happy to write a couple paragraphs on this if someone would
commit them into the Cocoon docs. I'll go ahead and put them on the wiki.
Lars
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]