Search code examples
djangopython-2.7django-registration

django-registration additional field in signup form


I am using django registration form and I want to add an extra field age to sign up form and i want to save that field to my model named profile.How can i do it.What will be my view?

my models.py

class Profile(models.Model):
    age = models.IntegerField()

Solution

  • You mention you have a model class which is my models.py

    class Profile(models.Model):
        age = models.IntegerField()
    

    I think in this case you may get help from this : Python/Django django-registration add an extra field