Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6062059
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T09:00:30+00:00 2026-05-23T09:00:30+00:00

I do something wrong, but I don’t know what. I try to combine django-registration

  • 0

I do something wrong, but I don’t know what. I try to combine django-registration 0.7 and form wizard but i getting error like this:

AttributeError at /
    'BoundField' object has no attribute 'strip
/home/celtrun/rails/neuroweb/site-packages/django/core/handlers/base.py in get_response
                        response = callback(request, *callback_args, **callback_kwargs) ...
▶ Local vars
/home/celtrun/rails/neuroweb/site-packages/django/utils/decorators.py in _wrapper
            return bound_func(*args, **kwargs) ...
▶ Local vars
/home/celtrun/rails/neuroweb/site-packages/django/utils/decorators.py in _wrapped_view
                    response = view_func(request, *args, **kwargs) ...
▶ Local vars
/home/celtrun/rails/neuroweb/site-packages/django/utils/decorators.py in bound_func
                return func(self, *args2, **kwargs2) ...
▶ Local vars
/home/celtrun/rails/neuroweb/site-packages/django/contrib/formtools/wizard.py in __call__
                return self.done(request, previous_form_list + [form]) ...
▶ Local vars
/home/celtrun/rails/neuroweb/apps/registration/views.py in done
              extra_context=None, formed=form_list[0]) ...
▶ Local vars
/home/celtrun/rails/neuroweb/apps/registration/views.py in register
                             send_email=True, profile_callback=None) ...
▶ Local vars
/home/celtrun/rails/neuroweb/apps/registration/models.py in create_inactive_user
        new_user = User.objects.create_user(username, email, password) ...
▶ Local vars
/home/celtrun/rails/neuroweb/site-packages/django/contrib/auth/models.py in create_user
            email_name, domain_part = email.strip().split('@', 1) '

As my FormWizard i have (r'^$', RegistrationWizard([RegistrationForm, CaptchaForm])),:

class RegistrationWizard(FormWizard,):
    def done(self, request, form_list):
        formed = form_list[0]
        register(request, success_url=None,
             form_class=RegistrationForm, profile_callback=None,
             template_name='base.html',
              extra_context=None, formed=form_list[0])
        return redirect('/accounts/register/complete/')
    def get_template(self, steps):
        return ['base.html', 'base.html']

class CaptchaForm(forms.Form):
    recaptcha = ReCaptchaField()       

Register function:

def register(request, success_url=None,
             form_class=RegistrationForm, profile_callback=None,
             template_name='registration/registration_form.html',
             extra_context=None, formed=None):
    if request.method == 'POST':
        if formed: form = formed
        if form.is_valid():
            username = formed['username'] 
            email = formed['email']
            password = formed['password1'] 
            RegistrationProfile.objects.create_inactive_user(username, password, email,
                             send_email=True, profile_callback=None)           
            return HttpResponseRedirect(success_url or reverse('registration_complete'))
    else:
        form = form_class()

    if extra_context is None:
        extra_context = {}
    context = RequestContext(request)
    for key, value in extra_context.items():
        context[key] = callable(value) and value() or value
    return render_to_response(template_name,
                              { 'form': form },
                              context_instance=context)

And create_inactive_user function of RegistrationProfile:

   def create_inactive_user(self, username, password, email,
                             send_email=True, profile_callback=None):
        new_user = User.objects.create_user(username, email, password)
        new_user.is_active = False
        new_user.save()

        registration_profile = self.create_profile(new_user)

        if profile_callback is not None:
            profile_callback(user=new_user)

        if send_email:
            from django.core.mail import send_mail
            current_site = Site.objects.get_current()

            subject = render_to_string('registration/activation_email_subject.txt',
                                       { 'site': current_site })
            # Email subject *must not* contain newlines
            subject = ''.join(subject.splitlines())

            message = render_to_string('registration/activation_email.txt',
                                       { 'activation_key': registration_profile.activation_key,
                                         'expiration_days': settings.ACCOUNT_ACTIVATION_DAYS,
                                         'site': current_site })

            send_mail(subject, message, settings.DEFAULT_FROM_EMAIL, [new_user.email])
        return new_user

I hope i did’t miss enything important to show. Thas someone know what error like this could means or help any other way?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T09:00:30+00:00Added an answer on May 23, 2026 at 9:00 am

    In your registerfunction you have:

    email = formed['email']
    

    email will point to the email form field not its value. To get the values of you fields, always use the cleaned_data dictionary of the form.

    (Same thing for username and password)

    Your code should be (in register):

    ...
    if request.method == 'POST':
       if formed: form = formed
       if form.is_valid():
          username = form.cleaned_data['username'] 
          email = form.cleaned_data['email']
          password = form.cleaned_data['password1'] 
          RegistrationProfile.objects.create_inactive_user(username, password, email,
                             send_email=True, profile_callback=None)
    ...
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm obviously doing something basic wrong but I can't figure it out and don't
Maybe I'm doing something wrong but I have a textarea where I've specified textAlign
I may be doing something wrong, but I haven't been able to find a
There is something wrong with this trigger. But what? CREATE TRIGGER MYCOOLTRIGGER AFTER INSERT
So obviously I am doing something wrong, but I just cannot seem to get
I'm sure I must be doing something wrong. But can't for the life of
I am currently doing this, but I am doing something wrong :): <Style TargetType={x:Type
Just tried to execute a small Lua script, but unfortunately I'm doing something wrong.
Gotta be something I'm doing wrong when converting the ttf with OpensIFRr, but I'm
I find this very strange, must be something I'm doing wrong, but still... I'm

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.