I'm guessing you want to store more information than default registration
allows you to when signing up users.

First hijack the URL for displaying the registration form so go to your
urls.py file and add this:

from path.to.form import CustomForm
........
urlpatterns = patterns('',
    #hijack this from registration
    url(r'^accounts/register/$', 'registration.views.register',
            {
             'backend':'path.to.custom.CustomBackend'},
name='registration_register'),
    url(r'^accounts/', include('registration.backends.default.urls')),
    .......
)

In your CustomBackend, your `get_form_class` method should return the form
that you want for registering users. Your register and activate methods
should take care of saving additional information to your defined User
Profile. The work flow of Registration's DefaultBackend class
(registration.backends.default) is usually sufficient so backend can just
inherit from it.

Check registration's source for inspiration and holla if you still need
assistance.

Sent from my Windows Phone
------------------------------
From: Okorie Emmanuel
Sent: 5/31/2013 4:26 PM
To: django-users@googlegroups.com
Cc: Okorie Emmanuel
Subject: Re: problem with extending django registration form



On Thursday, May 30, 2013 2:08:46 PM UTC+1, Tundebabzy wrote:
>
> Hi,
> Have you been able to sort out this issue?
> Why don't you create your own backend and shoe horn it into
> django-registration. You'll need to implement register, activate,
> registration_allowed, get_form_class, post_registration_redirect and
> post_activation_redirect methods (as needed) though.
>
> Sent from my Windows Phone
>
> -----Original Message-----
> From: Okorie Emmanuel
> Sent: 5/21/2013 3:04 PM
> To: django...@googlegroups.com <javascript:>
> Subject: problem with extending django registration form
>
> hi
>
> I have tried extending django registration page with little progress.
> I can now add new user from the admin but cannot do that on the
> front end. the problem is that the url does not display the from,
> but raises exception, "the page cannot be found". Do I need to create a
> view.py
> to be able to use  django registration app?
>
> here is my code
>
> http://pastebin.com/JBa8J1ry
>
> is there anything i have not
>



thanks tundebabzy for your reply

I have not solved the problem
The issue is that i don't understand how to implement the backend like you
suggest
can you give me a clue on this. thanks


-- 
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to