Hi, I set up my osqa site and want to add some additional openid provider to my login page, I added some coding in authentication.py as below, but it didn't work, actually, I got a logo on my login page, but when I click the logo, got error message "Sorry, but your input is not a valid OpenId", anyone has idea about it? do I need to recompile authentication.py or restart my server?

class additionalproviderAuthConsumer(OpenIdAbstractAuthConsumer):
    def get_user_url(self, request):
        return 'http://www.addtionalproviderdomain.com'

class addtionalproviderAuthContext(ConsumerTemplateContext): 
    mode = 'BIGICON'
    type = 'DIRECT'
    weight = 200
    human_name = 'addtionalprovider'
    icon = '/media/images/openid/addtionalproviderdomain.gif'

asked 10 Mar '11, 02:34

rohou's gravatar image

rohou
46158
accept rate: 0%

edited 10 Mar '11, 04:56

ripper234's gravatar image

ripper234 ♦
3.2k60116123


You need to restart, or if you're using wsgi, you can just touch the wsgi file. Also, you should add those in a separate module, just create a folder under forum_modules, and empty init.py file and a file named authentication.py with your providers code there.

link

answered 10 Mar '11, 06:26

Hernani%20Cerqueira's gravatar image

Hernani Cerq... ♦♦
16.8k65975
accept rate: 52%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×41
×3

Asked: 10 Mar '11, 02:34

Seen: 426 times

Last updated: 10 Mar '11, 06:26

powered by OSQA