[Zope] Using a DTML Method to render a DTMLDocument?
Cayce Ullman
c_ullman@yahoo.com
Mon, 22 Nov 1999 11:33:17 -0800 (PST)
Ok, here's what I'm trying to do, let's
say I have a bunch of DTMLDocuments that
I want to be able to call various different
DTMLMethod renderer's on. A poor example would
be, a DTMLMethod that adds a header and footer
to a DTMLDocument that doesn't have one.
For example :
MyDocument (DTMLDocument):
<H1> Hello World </H1>
--------------------------
MyMethod (DTMLMethod):
<H1> MY HEADER </H1>
<dtml-var this>
<H1> MY FOOTER </H1>
---------------------------
So when I call http://localhost/MyDocument/MyMethod
I get back :
MY HEADER
Hello World
MY FOOTER
So far, so good. The problem is, when MyDocument has
dtml in it, it does not render that dtml.
For example if :
MyDocument (DTMLDocument):
<H1> Hello World </H1>
<dtml-var someotherpage>
---------------------------
When I call http://localhost/MyDocument/MyMethod
I get back
MY HEADER
Hello World
<dtml-var someotherpage>
MY FOOTER
So I actually see the dtml tag rather than
the content of someotherpage. Is there away
to do this in DTML? I have figured out a way
to do it with an ExternalMethod (by manually
calling HTML.__call__ on it). But I wonder
if there is an easier way.
Thanks,
Cayce
__________________________________________________
Do You Yahoo!?
Bid and sell for free at http://auctions.yahoo.com