Andreas Hölzl wrote:
please allow me to post this previously posted mail again. the underlaying problems seems to be crucial for my understanding of Zope.
I have a serious namespace-problem when trying to put serveral dtml/zsql-methods together in one rendering act.
the problem:
first of all i try to render a dtml-method "base_method" located in "/root/subfolder/subsubfolder" via URL.
"base_method" is a layout template. inside "base_method" i call the dtml-method "db_query" located in "/root/subfolder/db_stuff" (!) for the output of a more complex db-query : ... <dtml-with db_stuff> <dtml-var "db_query(...)"> </dtml-with> ...
Zope finds "db_query" in "db_stuff" and renders it, but is not able to call zsql-methods also located in the same directory
[snip] This is probably because you are not passing the namespace to the DTML method. You need to do this explicitly when you call a DTML object in an expression. It is done for you when you call one by name. Try the following: <dtml-with db_stuff> <dtml-var "db_query(_.None,_,...)"> </dtml-with> This will pass the namspace (through the _ variable) to your dtml method which should allow it to find the other objects in the db_stuff folder and elsewhere. hth, -- | Casey Duncan | Kaivo, Inc. | cduncan@kaivo.com `------------------>