Greetings:
I was wondering about making a central login with PHP... the site uses PHP BB and already has therefore a MySQL database with login data inside it, is there an easy way to integrate the login (in kind of a portal fashion) for the entire site?
Thanks in advance,
Organizing an old site
Moderator: General Moderators
-
irishmike2004
- Forum Contributor
- Posts: 119
- Joined: Mon Nov 15, 2004 3:54 pm
- Location: Lawrence, Kansas
- feyd
- Neighborhood Spidermoddy
- Posts: 31559
- Joined: Mon Mar 29, 2004 3:24 pm
- Location: Bothell, Washington, USA
you'll need to use the _sid and _data cookies along with their sessions table and _users table they use to work with the user interaction. That's about it. Sounds a lot easier than it can be.
Have a look through login.php and sessions.php.
You will probably want to modify the lang_man.php file and constants file so you can show where they are in the pages...
Have a look through login.php and sessions.php.
You will probably want to modify the lang_man.php file and constants file so you can show where they are in the pages...
I have done something similar in the past, but in reverse order. when the user created an account on my site, I also created the phpBB account.
...if you need help on which tables to insert stuff, lemme know.
then on your login action page, you can set the cookie for phpBB so they don't have to log in twice.
Burr
...if you need help on which tables to insert stuff, lemme know.
then on your login action page, you can set the cookie for phpBB so they don't have to log in twice.
Code: Select all
$tempcookie = array('autologinid'=>md5($_POSTї"password"]),'userid'=>$getfiї"user_id"]);
setcookie("phpbb2mysql_data",serialize($tempcookie),time() + 31536000,"/");-
irishmike2004
- Forum Contributor
- Posts: 119
- Joined: Mon Nov 15, 2004 3:54 pm
- Location: Lawrence, Kansas
cool
Thanks for the input on this... I think it will work out pretty good with the cookie idea... thx burrito.
Mike
Mike