PriMoThemes — now s2Member® (official notice)

This is now a very OLD forum system. It's in READ-ONLY mode.
All community interaction now occurs at WP Sharks™. See: new forums @ WP Sharks™

How to pass password info for auto login

s2Member Plugin. A Membership plugin for WordPress®.

How to pass password info for auto login

Postby afurlan11 » April 25th, 2011, 9:48 pm

Hi-
I'm wondering if this is possible at all and if so how to do it:

I have my site, which registers a user. That registration information needs to be passed to a second site to register the user with the same information on that site. The login information needs to be the same on both sites so that a user can log in to my site and not even know they had to log into the second site.

I need to know how to pass the password upon registration (to create the second identical account) and then whenever that user logs into my site (to auto login to the second site).

Any help would be greatly appreciated!

Thanks!!
User avatar
afurlan11
Registered User
Registered User
 
Posts: 4
Joined: April 25, 2011

Re: How to pass password info for auto login

Postby Cristián Lávaque » April 26th, 2011, 12:09 am

You may find info on that here http://www.google.com/search?q=wordpress+share+users

I hope that helps. :)
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: How to pass password info for auto login

Postby afurlan11 » April 26th, 2011, 8:11 am

Thanks for the quick reply, but my issue is not between 2 wordpress blogs. It's between my wordpress site and a site being hosted completely separately from anything I'm doing.

Is that possible at all?
User avatar
afurlan11
Registered User
Registered User
 
Posts: 4
Joined: April 25, 2011

Re: How to pass password info for auto login

Postby Cristián Lávaque » April 26th, 2011, 10:58 am

Not normally. You need access to the database/scripts of both sites to do such an integration.

That said, if you use a login service like OpenID and such others, then you'd be sharing login info between several sites you don't have access to, but not just that other one specificially.

Sorry, I'm not sure how to help you here.
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: How to pass password info for auto login

Postby afurlan11 » April 28th, 2011, 10:53 am

I had a thought. If I can set a session variable of the user entered password before it is encrypted for compare against what is in the DB I think that will work. Where should I look to find where a user is authenticated upon login and also when a user registers (before encryption)?
User avatar
afurlan11
Registered User
Registered User
 
Posts: 4
Joined: April 25, 2011

Re: How to pass password info for auto login

Postby Cristián Lávaque » April 28th, 2011, 12:50 pm

I don't know if it can be done, passwords are quite protected in well written applications such as WordPress.

That said, I suggest you try Google and WordPress.org to find the way to de that, if possible.

I'm sorry I couldn't help you much with this. :|
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: How to pass password info for auto login

Postby afurlan11 » May 4th, 2011, 8:32 am

In case anyone else is looking for this answer, I figured it out. First you must make sure your php.ini has the setting register_globals set to off otherwise the session variables are erased on every page. Then in pluggable.php, you can grab the plain-text passwords, usernames, etc and set them as you would any php session variable. Then you can use your session variables in a url to pass, to display, etc.
User avatar
afurlan11
Registered User
Registered User
 
Posts: 4
Joined: April 25, 2011


Return to s2Member Plugin

Who is online

Users browsing this forum: Exabot [Bot], Google [Bot], Yahoo [Bot] and 2 guests

cron