[Zope] selected in select lists

Garry Saddington garry at schoolteachers.co.uk
Wed Oct 12 15:57:42 EDT 2005


I have a variable called 'groupabbrev' in the REQUEST. I am trying to 
automatically select an option in a select list based on this variable.
I have tried this code and many others, and many googles but have not 
found anything that works. Can anyone see what I am doing wrong?


<select name="groupabbrev">
<dtml-in getpastoralgroups>
<option value="<dtml-var groupabbrev>" <dtml-if 
expr="'groupabbrev'==_['sequence-item']"> selected</dtml-if> ><dtml-var 
groupabbrev></option>
</dtml-in>
</select>

regards
Garry



More information about the Zope mailing list