[Zope] creating dictionaries

Wade Simmons wsimmons@ep.newtimes.com
Thu, 16 Mar 2000 16:36:49 -0700


Try something like:
<dtml-call "d.update({key:value})">

- Wade


> I want to create a dictionary to eliminate some multiple occurences
> of data.
>  have two <dtml-in> tags and inside I want to add items to the
> dictionary:
>
> <dtml-let d="{}">
>         <dtml-in somesql1>
>                 <dtml-in somesql2>
>                        do something like: d[key]=value
>                </dtml-in>
>        </dtml-in>
>
> do something with the resulting dictionary...
> </dtml-let>
>
> so far so good. But how to I add items to the dictionary?
>
> <dtml-call "d[key]=value">  gives me syntax error.