cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Piroumian Konstantin <KPiroum...@protek.com>
Subject RE: [SUMMARY] JspReader/JspGenerator in 2.0.2
Date Thu, 11 Jul 2002 09:11:24 GMT
> From: Lajos Moczar [mailto:lmocz@galatea.com] 
> 
> Hi all -
> 
> I've seen several rather frustrated posts from users trying to figure 
> out how to make JspReader and/or JspGenerator work in Cocoon 
> 2.0.2. This 
> email describes how.
> 
> JspReader
> 
> Edit src/java/org/apache/cocoon/reading/JSPReader.java and 
> replace the 
> following lines (119-132):

<snip what="changes" />

I thought that I've fixed that, strange... I'll take a look at it.

> 
> The rebuild Cocoon and replace your existing cocoon-2.0.2.jar 
> with the 
> new one in build/cocoon/webapp/WEB-INF/lib.
> 
> Don't forget to copy jasper-compiler.jar from $CATALINA_HOME/lib to 
> WEB-INF/lib (or whatever JSP compiler you choose to use).

JSP samples work perfectly for me without this step in C2.0.3 and C2.1 and
Tomcat 4.1

> 
> Finally, if you are using a sub-sitemap, any references to 
> JSP files in 
> pipelines with either JspReader or JspGenerator must have the path 
> starting from the root cocoon context and MUST start with a leading 
> forward slash. Thus, if you have a sub-sitemap in a directory called 
> abc, with a JSP file in abc/jsps/hello.jsp, the src attribute 
> of either 
> component should be something like:
> 
> src="/abc/jsps/hello.jsp"

You won't need this in all cases. 
I've changed the behavior a while ago to allow relative links. The problem
happens when your sitemap uri perfix differ from your source path. In such
cases you have to use absolute paths. The problem is that I couldn't find a
way to resolve the current sitemap _source_ path to a relative to context
request path. Any suggestions are welcome.

See JSP samples in 2.1-dev version. They should work also in 2.0.3.

Konstantin


> 
> 
> Cheers,
> 
> Lajos
> 
> -- 
> galatea.com
> Cocoon training, consulting & support
> 
> 
> 
> ---------------------------------------------------------------------
> Please check that your question  has not already been answered in the
> FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.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/faq/index.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