<dtml-call expr="my_var='foo' "> fails
Hi! The following seems to be wrong: <dtml-call expr="my_var='foo' "> (I want to set the variable my_var of my python object) The DTML-File containing the dtml-call is a DTMLFile(...) of a python product <dtml-var expr="my_var"> is working How can I set a attribute of my object?
On Mon, Jan 21, 2002 at 05:22:01PM +0100, Thomas Guettler wrote:
<dtml-call expr="my_var='foo' "> (I want to set the variable my_var of my python object)
DTML does not support assignment. Rough equivalents are REQUEST.set and dtml-let. Oleg. -- Oleg Broytmann http://www.zope.org/Members/phd/ phd@phd.pp.ru Programmers don't die, they just GOSUB without RETURN.
Thomas Guettler writes:
How can I set a attribute of my object? You use an API, based on methods, for this.
If your attribute is a property, you use the "PropertyManager" or "PropertySheet" API (--> Zope integrated online help --> API reference). If it is an attribute of one of your products, provide adequate methods. If neither, use an External Method or XXXPythonScript. Dieter
participants (3)
-
Dieter Maurer -
Oleg Broytmann -
Thomas Guettler