Please send Cheetah problems to the Cheetah list, even if it's
related to a servlet. That way we don't bother the Webware
users who don't use Cheetah.
On Mon, Mar 25, 2002 at 05:50:41PM -0600, Tracy S. Ruggles wrote:
> Here's the problem: every once in a while, sections one and three
> may or not actually be sections one and three. Sometimes one will
> be three and vice versa, but never do they actually swap places,
> i.e. it never happens that I get Three/Two/One, just sometimes
> Three/Two/Three and One/Two/One. In my actual set of pages, I'm
> define seven placeholders in the master template and only the
> placeholders that weren't over-ridden in the sub-pages exhibit this
It looks like you have #def and #block reversed. #block belongs
in the parent template, _master.tmpl:
<P> This block has not been overridden.</P>
This both sets the location of the output and provides default
text. Then the child template may do (or not do):
<P>This is my custom content for section Two.</P>
It's possible to use #def in the parent too, but then you have to
explicitly set the location of the output:
or it won't appear at all. If Cheetah encounters '$sectionTwo'
before '#def sectionTwo' it *should* raise a NameMapper.NotFound
exception, but perhaps something is happening in the way the
parent and child templates are being processed under Webware.
Try replacing the '$section*' in _master.tmpl with #block's,
and using #def in _pageA.tmpl, and getting rid of the
'#def ... #include ... #end def' constructs, and see if that
clears up your problem.
-Mike (Iron) Orr, iron@... (if mail problems: mso@...)
http://iron.cx/ English * Esperanto * Russkiy * Deutsch * Espan~ol