On 7/11/07, Cole Tuininga <[EMAIL PROTECTED]> wrote:
>
> Hey all - I'm a newforms newbie running 0.96.  I was just wondering if
> there was a way to create fields for a newform dynamically.  Some of
> the fields are coming from a database and hence, could change when the
> form is created.

Yes. You can add new fields to the self.fields list in the __init__
method for your form.

> Also, is there any documentation on select boxes with newforms somewhere?

All the available documentation for newforms is here:

http://www.djangoproject.com/documentation/newforms/

This includes some documentation of Select and SelectMultiple form
fields. The other possible source of documentation is the model_forms
model test, and the forms regression test, distributed in the test
directory of the Django sources. This isn't really documentation, but
it is working examples of pretty much every widget and field in
action.

Yours,
Russ Magee %-)

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to