# SSO - Two Feature Requests

**URL:** https://meta.discourse.org/t/sso-two-feature-requests/59884
**Category:** WordPress
**Created:** [March 25, 2017, 5:32pm UTC](https://meta.discourse.org/t/sso-two-feature-requests/59884 "2017-03-25T17:32:38Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Hosker4u](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hosker4u/32/116199_2.png) [@Hosker4u](https://meta.discourse.org/u/Hosker4u)
#### Post date: [March 25, 2017, 5:32pm UTC](https://meta.discourse.org/t/sso-two-feature-requests/59884/1 "2017-03-25T17:32:38Z")

</div>

This plug-in works great, it is missing two things in my opinion.

**1. Logout both WordPress and Discourse**  
If a user logs out of Discourse they remain logged into WordPress.

**2. Transfer new Discourse Registrations to WordPress**  
If a user registers on Discourse.  
They come back the next day and click LOGIN on WordPress. It will fail.  
They instead have to click the “Login with Discourse” button. A usability issue?

How to fix (1) I have no idea. How to fix (2) however half of the code must be there? as with SSO if I click the “Login with Discourse” it creates the user. Why not create it on registration?

Love to know if plug-in can be updated for (2), before I bash together a script that if a username does not exist in WordPress but does exist on Discourse. To then transfer the user to the SSO URL? .. They will only have to do this once.

---

<div class="post-metadata">

### Author: ![simon](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/simon/32/339122_2.png) [@simon](https://meta.discourse.org/u/simon)
#### Post date: [March 25, 2017, 6:05pm UTC](https://meta.discourse.org/t/sso-two-feature-requests/59884/2 "2017-03-25T18:05:56Z")

</div>

> [@Hosker4u](#):
>
> 1. Logout both WordPress and Discourse  
> If a user logs out of Discourse they remain logged into WordPress.

You can do this now. Search for ‘logout redirect’ on your Discourse forum’s settings page. Add the url `http://yoursite.com/?request=logout` to that field.

> [@Hosker4u](#):
>
> 1. Transfer new Discourse Registrations to WordPress  
> If a user registers on Discourse.  
> They come back the next day and click LOGIN on WordPress. It will fail.  
> They instead have to click the “Login with Discourse” button. A usability issue?

I’ll look at this some more. The easiest approach would be to style the ‘Login with Discourse’ link as a button.

---

<div class="post-metadata">

### Author: ![simon](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/simon/32/339122_2.png) [@simon](https://meta.discourse.org/u/simon)
#### Post date: [March 25, 2017, 8:44pm UTC](https://meta.discourse.org/t/sso-two-feature-requests/59884/3 "2017-03-25T20:44:42Z")

</div>

> [@Hosker4u](#):
>
> if I click the “Login with Discourse” it creates the user. Why not create it on registration?

This could be done with a Discourse web hook, but it’s a lot easier to just let the user be created when they click on the link. Would something like this solve the problem? (the logo would need to be configurable)

 ![](https://global.discourse-cdn.com/meta/original/3X/b/4/b4bbbea3c93fd990805d387008a4cb3303c02991.png)
