[Zope] DTML Container?

Steve Spicklemire steve@spvi.com
Tue, 8 Feb 2000 08:33:25 -0500 (EST)


Hi Mike,

>>>>> "Mike" == Mike  <mike@if-site.com> writes:

    Mike> I have two objections:

    Mike> 1) aggregation is NOT inheritance.  2) when you try index
    Mike> such object in ZCatalog (I mean full text index) you get
    Mike> story_dtml indexed, not object itself. How will you handle
    Mike> such catalog entries?

OK .. good point. It's a tradeoff between work up front

(If you're going to do *that* much development... make a
product in Python and you get fine-grained control over all
the properties and behaviors you want/need)

and elegance. On the shy side of elegance you might try beginning
all your 'story' dtml documents with a call to a dtml method
of the ZClass like this:

<dtml-var beginStory>

where beginStory is something like:

<dtml-if "id()=='story_dtml'"> 
<dtml-call "RESPONSE.redirect(URL1)">
</dtml-if>

I know.. it's a hack. You could clean it up a little... but it would
work.. and you'd get all the benefits of a simple ObjectManager.

-steve



    >>  which can then us all the tags your're talking about freely?
    >> 
    >> more soon I'm sure... ;-) -steve

    Mike> Steve, my English is much better than your Russian ;-)

    Mike> Mike