[Zope-dev] problems rendering a dtml method

Federico Di Gregorio fog@mixadlive.com
Mon, 3 Apr 2000 16:43:38 +0200


hi,

	here again with problems in the Translator product: inside the
render() method of the dtml-localize tag i do some magic to find suitable
Translators and then i ask them for the argument of the tag. sometimes
this argument is a dtml method inside a subfolder and the object returned
(by a default getitem()) is an Acquisition.ImplicitAcquirerWrapper. 

	the method uses some properties dtml-let-ed above (the properties
are there, i can see them in the md passed as an argument to render())
but i don't know how to pass the md to it. using something like:

for t in translators:
    try:
        v = t.translate(val)
	if hasattr(v, '__call__'): return v(md)
        else: return str(v)
    except AttributeError:
	pass
raise AttributeError(val)

but the v(md), obviously does not work and i get an AttributeError from
inside the dtml method.

any ideas?
federico
 
-- 
Federico Di Gregorio
MIXAD LIVE System Programmer                           fog@mixadlive.com
Debian GNU/Linux Developer & Italian Press Contact        fog@debian.org
                           Don't dream it. Be it. -- Dr. Frank'n'further