Hmm, ok. I kind of just used something a little different, probably not as efficient but it seems to be giving the correct results, but it's not giving me the correct output.
Wondering if you can help me out with this as I am completely stumped.
I have a database field called auth. It is 4 characters long. And I have something like 3333, for all administrator permissions.
So, what I do is grab that from the database, get the permission i need using $var{0}.
And then compare it with $functions->get_user_level().
$functions->get_user_level() outputs as 3.
$var{0} outputs as 3.
But when i do the comparison with an if statement. It won't work, and won't even display the results I want it too.
/* //Make sure the user has permission
if ( !$functions->get_user_level() >= $auth{0} ) {
//
// Kick to login
//
$functions->redir_to_login();
} else {
//Do something elese
}
Even if i take out the
!, either way, it just displays:
Quote
You don't have the appropriate permissions to do this. If in doubt, contact the administrator.
Even though I don't have that message coded anywhere in, so I am starting to think that it is a UseBB thing creating the message?