[Zope] DTML-stuff calling from Python Script

Oleg Broytmann Oleg Broytmann <phd@phd.pp.ru>
Tue, 8 Jan 2002 18:51:15 +0300


return context.doc_here(context, context.REQUEST)

On Tue, Jan 08, 2002 at 04:44:17PM +0100, bogdan@iuveno-net.de wrote:
> How to call an DTML Method from Python Script? It could be same as from
> DTML stuff: <dtml-var somewhere.script(value)> or <dtml-call expr="...">
> 
> But vice versa (dtml-method from script) always fails in anyway:
> ------------------------
> print context.doc_here
> return printed
> ------------------------
> Works, but just prints the source (not parses)
> 
> ------------------------
> return context.doc_here(_,_)
> ------------------------
> Fails with "guarded_getattr"
> 
> ------------------------
> return context.doc_here(_)
> ------------------------
> Fails with "standard_html_header" (key_error)
> 
> ------------------------
> return context.doc_here
> ------------------------
> Works, but just prints the source (quoted, not parses)
> 
> Anybody know how to call it? Documentation claims, that it should work.
> But it does not.
> 
> P.S. Namespace defined as well.

Oleg.
-- 
     Oleg Broytmann            http://phd.pp.ru/            phd@phd.pp.ru
           Programmers don't die, they just GOSUB without RETURN.