i have the following problem: i have a dtml method with a title property set, and in the dtml i include standard_html_header, which contains <title><dtml-var title_or_id></title>. i dont get the dtml method's title rendered, but the containing folder's id . if i set a title property for the folder, it renders that, but i have multiple dtml methods which all have different titles so its obvious... -jonathan
DTML Methods don't have their own namespace, they use that of their parent. That's why you're getting the title/id of the containing folder. Use a DTML Document instead... that should give you what you want. HTH, Dylan At 03:47 AM 11/4/2002 +0100, you wrote:
i have the following problem: i have a dtml method with a title property set, and in the dtml i include standard_html_header, which contains <title><dtml-var title_or_id></title>.
i dont get the dtml method's title rendered, but the containing folder's id . if i set a title property for the folder, it renders that, but i have multiple dtml methods which all have different titles so its obvious...
-jonathan
_______________________________________________ Zope maillist - Zope@zope.org 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 )
On Mon, 2002-11-04 at 04:10, Dylan Reinhardt wrote:
DTML Methods don't have their own namespace, they use that of their parent. That's why you're getting the title/id of the containing folder. Use a DTML Document instead... that should give you what you want.
but then in my dtml document i cant do what i can in dtml methods... j
On Mon, Nov 04, 2002 at 05:15:21AM +0100, jonatan wrote:
On Mon, 2002-11-04 at 04:10, Dylan Reinhardt wrote:
DTML Methods don't have their own namespace, they use that of their parent. That's why you're getting the title/id of the containing folder. Use a DTML Document instead... that should give you what you want.
but then in my dtml document i cant do what i can in dtml methods...
You can't? DTML Methods and DTML Documents are nearly the same thing, except that DTML Methods are -- as the name would imply -- effectively just methods of their containers, rather than stand-alone, contentish objects like DTML Documents. This subtle difference is why DTML Methods are categorized as presentation objects (meant to do interesting things on other objects in their container) and DTML Documents are categorized as content objects. From that perspective, you'll understand why when you refer to a property in your DTML Methods, you're getting the property of its container, rather than the property of the method itself. Refer to the relevant chapter in the Zope Book, "Basic DTML": http://www.zope.org/Documentation/Books/ZopeBook/2_6Edition/DTML.stx or the How-To on the subject: http://www.zope.org/Members/michel/HowTos/DTMLMethodsandDocsHowTo If that still doesn't clear up the issue, please elaborate on what you can't do with a DTML Document that you can do with a DTML Method. Brad
participants (3)
-
Brad Bollenbach -
Dylan Reinhardt -
jonatan