misterfade
06-22-2005, 10:09 AM
Hi,
I have a page setup that anyone can see, but the info displayed depends if the user is logged in or logged in and part of a certain usergroup. That part I have down.
The top:
chdir("/path/to/forums/");
require('./global.php');
include('./includes/functions_user.php');
$session['sessionhash'] = fetch_sessionhash();
Where the login/info is:
if ($bbuserinfo['userid']!=0 && $bbuserinfo['usergroupid'] == 12) {
echo "Welcome!";
} elseif ($bbuserinfo['userid']!=0) {
echo "You do not have access to this section.";
} else {
Now I have a separate database that I created with a list of users, they have the same name as the forums, but it also contains lots of other stuff, which I want to display once they're logged in. How would I set it so that when that member logs into that page, it also shows them their info from the other database? I tried:
if ($bbuserinfo['userid']!=0 && $bbuserinfo['usergroupid'] == 12 && $bbuserinfo['username'] == $row_artists['username'])
but that doesn't work. I don't get any errors, it's just that it doesn't do what I want it to.
I know this seems confusing but if anyone can help me out it would be great.
Thanks.
I have a page setup that anyone can see, but the info displayed depends if the user is logged in or logged in and part of a certain usergroup. That part I have down.
The top:
chdir("/path/to/forums/");
require('./global.php');
include('./includes/functions_user.php');
$session['sessionhash'] = fetch_sessionhash();
Where the login/info is:
if ($bbuserinfo['userid']!=0 && $bbuserinfo['usergroupid'] == 12) {
echo "Welcome!";
} elseif ($bbuserinfo['userid']!=0) {
echo "You do not have access to this section.";
} else {
Now I have a separate database that I created with a list of users, they have the same name as the forums, but it also contains lots of other stuff, which I want to display once they're logged in. How would I set it so that when that member logs into that page, it also shows them their info from the other database? I tried:
if ($bbuserinfo['userid']!=0 && $bbuserinfo['usergroupid'] == 12 && $bbuserinfo['username'] == $row_artists['username'])
but that doesn't work. I don't get any errors, it's just that it doesn't do what I want it to.
I know this seems confusing but if anyone can help me out it would be great.
Thanks.