Reputation: 5550
I have a django form, with values initialized.But i dont want the values to be displayed to the user.I am using {{formobject.fieldname}} in template but it displays the value too.Is there any option to hide the field value alone?
Upvotes: 0
Views: 892
Reputation: 309099
Initialise a second, unbound form in your view,
blank_form = MyForm()
then use this form to render your blank fields in the template.
{{ blank_form.fieldname }}
Upvotes: 1