views:

335

answers:

3

We have an existing WordPress install with a thriving user base.

There are also some new Web applications being built in Rails to cover some new functionality.

Any suggestions or tips on integrating sign-on between WP and a Rails app?

Anyone done anything like this before?

A: 

Something like this? Rails Integration API, although it might be the opposite of what you want (i.e. it makes WP talk to existing rails authentication system, not the other way around).

If not, you can just write some code to interact directly with the WP database. This seems to be the best bet right now.

Artem Russakovskii
I looked at that plugin but it's not 2.8 compatible and seems to have been somewhat abandoned. Recent changes in WP and Rails mean it doesn't work out of the box. Have you used it with success?
Hunter
I basically ended up writing my own WordPress plugin to handle this. Just FYI in case anyone else runs into this issue.
Hunter
A: 

If the two applications are running on the same subdomain, you would be able to look at the cookie which is set when you're signed into wordpress. Once the cookie is there, you can grab the member info from the WP database, using the session id in the cookie.

blockhead
Have you done this with success? Any caveats?
Hunter
Honestly I have not, but it makes sense in theory to me.
blockhead
A: 

Hi Hunter, I have the exact same need, could you please share the plugin you eventually developed ? Thanks ! Alex

Alex