db.define_table('test',
Field('Q1',label='This is the question one', comment='Answear the
question'),
Field('Q2',label='This is the question two', comment='Answear the
question'),
.........
........
Field('created_on', 'datetime', default=request.now),
Field('created_by', db.auth_user, default=auth.user_id),
)
2010/8/18 Bruno Rocha <[email protected]>
> You can use FORM(), and also use the table configuration to define
> questions,
> you can use the arguments "label" and "comment" on field definition.
>
> After that, you can use CSS to improve the form layout.
>
> You can't create a new field to store the login info and putting by default
> the auth.user value?
>
> 2010/8/18 dlin <[email protected]>
>
> I want a form like:
>>
>> Question Answer
>> Q1..... ____
>> Q2..... ____
>> Q3..... ____
>> [submit]
>>
>> Q1,Q2,Q3 and correct answer is stored in a table.
>> But the 'Answer' field should combined with login user's answer.
>>
>> What's the best way to display the form to user?
>> Do you suggest use FORM() in control or use <form> in view?
>>
>
>
>
> --
>
> http://rochacbruno.com.br
>
--
http://rochacbruno.com.br