[Django]-How does {{ field }} display a field widget in a django template?

3👍

It all comes down to:

>>> str(form['name'])
'<input id="id_name" type="text" name="name" value="Django" maxlength="100" />'

I guess that’s what the for loop in your template iterates over.

👤Dunno

Leave a comment