开发者

Django + socialauth: login with openid or admin

i'm trying to implement the socialauth module to my django project, but i get a bit c开发者_开发技巧onfused on its relation toward the admin site.

My problem: the @login_required decorator redirects me to the admin login page instead of the accounts/login/ page to log in via openid.

  • how do i offer the possibility to the user to log in via admin or openid?

thanks


the solution:

  • in settings.py, change LOGIN_URL = 'admin' to LOGIN_URL = '/accounts/login/'
  • in urls.py add (r'^accounts/', include('socialauth.urls')),
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜