----- Original Message -----
From: "Kapil Thangavelu" <[EMAIL PROTECTED]>
To: "Tim Hicks" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Saturday, September 02, 2000 3:59 PM
Subject: Re: [Zope] How to access id and title of document calling
standard_html_header


> Tim Hicks wrote:
> >
> > For those of you who saw my posts from a couple of days ago
(Dieter
> > Maurer and Geir Bfkholt), this is the question that I think I
should
> > have been asking in the first place.
> >
> > I have a standard_html_header that is inserted into Zclasses.
These
> > Zclasses have properties including meta_author, meta_description
etc
> > (I don't think it is important what they are, just that they are
> > properties that standard_html_header does not have).  In the
> > standard_html_header, I use code such as <dtml-var meta_author>
and
> > <dtml-var meta_description>.  This works fine and the properties
of
> > the *zclass* are inserted.  However, if I put <dtml-var id> into
the
> > standard_html_header, I get the id of standard_html_header, *not*
of
> > the zclass.  How do I tell zope to which item I am refering
(bearing
> > in mind, I don't know the name of the zclass ie it is variable)?
> >
> > Cheers
>
>
> Make your standard_html_header a DTML Method not a Document. Methods
> operate on their containers. Documents operate on themselves. The
> Document is acquiring the ZClass properties after looking through
its
> own. The Method looks for the properties of its containers.
>
> Kapil
>

It is a method already!  Any ideas.  If it makes any difference, I'm
running Zope 2.2.0 (although I really don't think this is important).

tim


_______________________________________________
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )

Reply via email to