Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.

I want users of my existing web application users could access question to answer?

+1 vote
asked Sep 11 in Q2A Core by kumarharish
I have already developed a web application. Now I want users of my existing web application could access question to answer app without relogin(entering credentials again) and want to keep question 2 answer database separately. My web app user could directly go to question answer site and also can come back to my web app.

1 Answer

+1 vote
answered Sep 11 by Scott

Yes this is possible using Single Sign On.

In short: rename the qa-external-example folder to qa-external then open the qa-external-users.php and follow the instructions.

commented Sep 11 by kumarharish
I have tested this. I set my existing db credentials in qa-config.php. As i access my web app it created all q2a required tables in my existing web database. I want q2a database separately and want to switch between my two existing web applications. 2 existing web application +1 question 2 answer. these are 3 web applications and I want to switch among them without relogin.
commented Sep 11 by Scott
Then in qa-config.php you should put a different database. Note that for SSO you need to edit the function qa_get_mysql_user_column_type before you install Q2A. After installation you can edit the other functions, e.g.
qa_get_login_links should return the login/register URLs for your web app
qa_get_logged_in_user should return the details of the currently logged in user. Here you'll need to connect to your separate database or do whatever you need to verify who is logged in.