cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Neeme Praks" <ne...@one.lv>
Subject Cocoon2 running with Tomcat + directory rendering issue (possible bug?)
Date Sun, 21 May 2000 18:30:52 GMT

I successfully managed to get Cocoon2 running with Tomcat 3.1 beta (on
W2K).
I would also document this, and I have a question regarding the
documentation. Are these XML files written by hand? Or is there some
existing editor for this? I suspect that they are written by hand?

Also, after playing around with Cocoon2 and trying out the samples, I
found that the directory rendering doesn't work on the root directory
("/servlet/Cocoon/")... When processing the URI, the CocoonServlet
always removes the first slash from the URI. However, in the case of
root directory, this results in empty URI. I fixed it by adding a check
for the length of the URI:

Index: CocoonServlet.java
===================================================================
RCS file:
/home/cvspublic/xml-cocoon/src/org/apache/cocoon/servlet/Attic/CocoonSer
vlet.java,v
retrieving revision 1.1.4.8
diff -r1.1.4.8 CocoonServlet.java
119c119
<             if (uri.charAt(0)=='/') uri=uri.substring(1);
---
>             if (uri.charAt(0)=='/' && uri.length() > 1)
uri=uri.substring(1);


Is this ok?
Neeme

Mime
View raw message