[Zope] Bug/Problem with Zope 2.6.0b2
Aaron Optimizer Digulla
Aaron Optimizer Digulla <digulla@hepe.com>
Sun, 20 Oct 2002 15:25:17 +0200
Hello,
I've create a small website along these lines:
index_html is a DTML which uses various scripts and parts in the
current folder. One of these parts is "contentLayout" which is
a Python script which in turn reads "contents". This works
very well.
I get problems when I add subfolders. Example: I add a subfolder
"news" which contains the same structure as the Elvis tutorial
Step 11: I add a DB connector, a "getNEWS" DTML and then in "contents",
I write:
<dtml-in getNEWS>
<p><dtml-var date> -- Reported by <dtml-var name></p>
<p><dtml-var description></p>
<hr>
</dtml-in>
Unfortunately, when I browse "http://.../test/news", I get
KeyError
getNEWS
The overall layout looks like this:
index_html
contentLayout
contents
news/getNEWS
news/contents
index_html reads contentLayout which reads context.contents.
This all seems to work but when "news/contents" is read,
"news/getNEWS" is not found. Interestingly enough, when I add
a Script "news/test" which contains:
return "Test"
and change news/contents to:
<dtml-var test>
then I get no error but a page with my complex layout and the
word "Test" at the correct place.
Then I tried to replace the DTML news/contents with a Python
script and voila: It works! context.getNEWS() returns the desired
result.
Any ideas?
--
==============================================
Sowatec AG, CH-8330 Pfäffikon (ZH)
Witzbergstr. 7, http://www.sowatec.com
Tel: +41-(0)1-952 55 55
Fax: +41-(0)1-952 55 66
----------------------------------------------
Aaron "Optimizer" Digulla, digulla@sowatec.com
==============================================