I'm still a newbie when it comes to django, but I've installed both django-profiles and django-registration, and running the latest django 1.5.1. I've also read a few guides, namely http://dmitko.ru/django-registration-form-custom-field/, http://birdhouse.org/blog/2009/06/27/django-profiles/, Django-Registration & Django-Profile, using your own custom form
I've not customized django-registration but I've tried to make my own profiles class that looks something like this:
from django.contrib.auth.models import User
class UsrProfile(models.Model):
user = models.ForeignKey(User, unique=True, primary_key=True)
...custom fields here...
But I understand that it's possible to have users register but it's a separate thing to have profiles, in that users can register without having to create a profile.
My question is, how can I stick in the profiles class I made, into the registration? I want to force users to fill out details I specified in my profiles class when they are registering...
I've tried following some tutorials/guides here and there but I also keep getting stuck whenever they say to modify the urls.py to something like:
url(r'^accounts/register/$',
register,
{'backend': ... form_class...
),
because whenever I try this, the 'register' (in the second line) doesn't seem to be recognized and I have no idea what it's referring to either....I try something like:
from registration.views import register
but it doesn't seem to recognize register as a valid import...