On 25.10.05 at 13:29:04 [+0200], Gergana Silvanova <[EMAIL PROTECTED]> wrote: > Hello, > > I have one "select" field, and depending on my > selection, I want to display an "input" field or > another "select" field, next to it. > > Is there a way to do this in Zope? > > In general, I think that DTML does not give you much > freedom to have dynamic content.
Gergana, first of all I suggest using ZPT instead of DTML. You might then do something like <block tal:condition="python: test(mytest(), 1, 0)"> <select> <option></option> </select> </block> This will work in very simple situations. For more complex situations you will probably want to break your logic (here the "test") into a PythonScript and you might want to look at using Macros for reusing this element in different templates. Charlie -- Charlie Clark eGenix.com Professional Python Services directly from the Source >>> Python/Zope Consulting and Support ... http://www.egenix.com/ >>> mxODBC.Zope.Database.Adapter ... http://zope.egenix.com/ >>> mxODBC, mxDateTime, mxTextTools ... http://python.egenix.com/ ________________________________________________________________________ ::: Try mxODBC.Zope.DA for Windows,Linux,Solaris,FreeBSD for free ! :::: _______________________________________________ Zope-DB mailing list [email protected] http://mail.zope.org/mailman/listinfo/zope-db
