Thursday, February 2, 2012

Re: Help Me With omab/django-socialauth

I took your config and its working fine, maybe your twitter api key is
wrong?

On 02.02.2012 11:22, coded kid wrote:
> I'm getting a redirect loop error. Whats the probs?
>
> On Feb 1, 1:22 pm, Thorsten Sanders<thorsten.sand...@gmx.net> wrote:
>> Some sort of error traceback/description would be helpful, from a quick
>> look it seems all right.
>>
>> On 01.02.2012 13:23, coded kid wrote:
>>
>>
>>
>>> Hey guys, I'm facing a huge problem with omab/django/socialauth.
>>> After setting all the necessary settings, I clicked on the Enter
>>> using Twitter link on my homepage, it couldn t redirect me to where I
>>> will enter my twitter username and password. Below are my settings.
>>> In settings.py
>>> INSTALLED_APPS = (
>>> 'social_auth',
>>> }
>>> TEMPLATE_CONTEXT_PROCESSORS = (
>>> "django.core.context_processors.auth",
>>> "django.core.context_processors.debug",
>>> "django.core.context_processors.i18n",
>>> "django.core.context_processors.media",
>>> "django.core.context_processors.static",
>>> "django.contrib.messages.context_processors.messages",
>>> "django.core.context_processors.request",
>>> social_auth.context_processors.social_auth_by_type_backends ,
>>> )
>>> AUTHENTICATION_BACKENDS = (
>>> 'social_auth.backends.twitter.TwitterBackend',
>>> 'django.contrib.auth.backends.ModelBackend',
>>> )
>>> SOCIAL_AUTH_ENABLED_BACKENDS = ('twitter')
>>> TWITTER_CONSUMER_KEY = '0hdgdhsnmzHDGDK'
>>> TWITTER_CONSUMER_SECRET = 'YyNngsgw[1jw lcllcleleedfejewjuw'
>>> LOGIN_URL = '/accounts/login/' #login form for users to log in with
>>> their username and password!
>>> SOCIAL_AUTH_LOGIN_REDIRECT_URL = '/homi/' #page after user get
>>> authenticated
>>> SOCIAL_AUTH_NEW_ASSOCIATION_REDIRECT_URL = '/homi/' ' #page after
>>> user get authenticated
>>> SOCIAL_AUTH_ERROR_KEY='social_errors'
>>> SOCIAL_AUTH_COMPLETE_URL_NAME = 'socialauth_complete'
>>> SOCIAL_AUTH_ASSOCIATE_URL_NAME = 'socialauth_associate_complete'
>>> from django.template.defaultfilters import slugify
>>> SOCIAL_AUTH_USERNAME_FIXER = lambda u: slugify(u)
>>> SOCIAL_AUTH_UUID_LENGTH = 16
>>> SOCIAL_AUTH_EXTRA_DATA = False
>>> In urls.py
>>> url(r'', include('social_auth.urls')),
>>> In my template:
>>> <p>
>>> <a href="{% url socialauth_begin 'twitter' %}">Enter using Twitter</
>>> a>
>>> </p>
>>> </form>
>>> What do you think I m doing wrong? Hope to hear from you soon. Thanks
>>> so much!
>>> N:B : I m coding on windows machine. And in the development
>>> environment using localhost:8000.

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

No comments:

Post a Comment