I have these objects: A is calling B is calling (D and E) My directory layout is: /map/ /map/sql /map/util /map/report/report1 /map/report/report2 /map/report/report3 Method A in "report1" is rendering B in "util". B is rendering a ZSQL-object in "sql" and in the tag <dtml-in> is rendering C (python-method) in "util", to render a table cell, but this isn't working, because E is unknown and I don't know why. Example: DTML-Method A: <dtml-in "sql.list_mytable" prefix="pre"> <dtml-var "util.B(index=pre_index)"> </dtml-in> DTML-Method B <td> <dtml-var expr="C(index=index)"> </td> Here is Zope breaking because Zope can't find method C. Could someone help? Ralph
Ralph wrote at 2005-6-15 20:59 +0200:
... Method A in "report1" is rendering B in "util". B is rendering a ZSQL-object in "sql" and in the tag <dtml-in> is rendering C (python-method) in "util", to render a table cell, but this isn't working, because E is unknown and I don't know why.
Example:
DTML-Method A: <dtml-in "sql.list_mytable" prefix="pre"> <dtml-var "util.B(index=pre_index)">
I assume "B" is a DTML object... Then, you make one of the most frequent errors when dealing with "DTML" objects. They have 2 essential positional arguments. If you forget to pass them (usually as "None, _"), then the called DTML object gets a new empty namespace... For details, please the the "Calling DTML objects" section in <http://www.dieter.handshake.de/pyprojects/zope/book/chap3.html> -- Dieter
On Thursday 16 June 2005 19:24, Dieter Maurer - dieter@handshake.de wrote:
Ralph wrote at 2005-6-15 20:59 +0200:
For details, please the the "Calling DTML objects" section in
Thank you for the answer. It was a simple programming failure, after 12h of working.
participants (2)
-
Dieter Maurer -
Ralph