[Zope-DB] Drop down list from database

Charlie Clark charlie at begeistert.org
Thu Nov 20 05:39:15 EST 2003


On 2003-11-20 at 10:25:40 [+0100], RI Dunfey wrote:
> 
> 
> Hi,
> 
> I am looking for simple example of populating a drop down list box with 
> records from a table of possible answers.  Does anybody know the location 
> of a simple example.

Assuming you've got a ZSQL-method in your folder called qAnswers

<select>
<option tal:repeat="result here/qAnswers"
		tal:attributes="value result/value"
		tal:content="value result/value">this is the option</option>
</select>

Should work. Check out the ZPT documentation.

Charlie



More information about the Zope-DB mailing list