Op zondag 11-03-2007 om 15:48 uur [tijdzone +0100], schreef Horst
Gutmann:
> enquest schrieb:
> >
> > Second question: how can you add a password field from the newforms. you
> > can't define ("correct me if I'm wrong") a password field in the
> > model... And I don't see any option to give a field a password field.
> >
> > How can I do this?
> >
> > Thanxs
> >
>
> I haven't really tried it so this is probably just a wild guess, but the
> form_for_model function has a formfield callback function that will be
> executed on each field in your model and returns a new instance of the
> FormField to be used for the respective field.
>
> If you then instantiate your password field to use a CharField that uses
> the PasswordInput widget I think it should work :-) (But again: Wild
> guess ;-) )
>
> Best regards
>
> >
Could you give an example so that I better can understand this.
Enquest
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to [email protected]
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
-~----------~----~----~----~------~----~------~--~---