help with running a dtml method
Hi I have a site with the following folder structure in zope: Dvir WebSite contentPages I have and index_html in the WebSite folder, in it I call a dtml method that's in the contentPages folder named overview_html, in the same folder (content Pages) I have another dtml_method named time_combo. In the overview_html I try to call the time combo method - I tried: <dtml-var time_combo> But it keeps saying it has an error : Error Type: NameError Error Value: name 'time_combo' is not defined I tried putting the full path like this: <dtml-var expr="Dvir <http://10.101.1.106:8080/Dvir/manage_workspace> .WebSite <http://10.101.1.106:8080/Dvir/WebSite/manage_workspace> .contentPages <http://10.101.1.106:8080/Dvir/WebSite/contentPages/manage_workspace> .time_combo()"> But it still won't work. Any idea what I did wrong? And what do I need to do to be able to call it?
Dvir Bar-lev wrote at 2009-3-26 10:12 +0200:
I have a site with the following folder structure in zope: Dvir WebSite contentPages
I have and index_html in the WebSite folder, in it I call a dtml method that's in the contentPages folder named overview_html,
in the same folder (content Pages) I have another dtml_method named time_combo.
In the overview_html I try to call the time combo method - I tried:
<dtml-var time_combo>
But it keeps saying it has an error :
Error Type: NameError Error Value: name 'time_combo' is not defined
Unlike a "DTMLDocument", a "DTMLMethod" does not change the context from name lookup. Depending on how you call the method you may even loose all context. To learn more about DMTL calling, read http://www.handshake.de/~dieter/pyprojects/zope/book/chap3.html#c37ac15c14b5 -- Dieter
participants (2)
-
Dieter Maurer -
Dvir Bar-lev