09-07-2016, 04:32 AM
Recommendation: around line 373 of us_helpers.php where you have this code:
if(isset($user) && $user->data() != null){
if($user->data()->permissions==0){
bold('<br><br><br>Sorry. You have been banned. If you feel this is an error, please contact the administrator.');
die();
}
}
Instead of printing a message and dying, (1) log that user out and (2) redirect them to the login screen with a message:
Redirect::to($us_url_root.'users/login.php?err=Sorry. You have been banned. If you feel this is an error, please contact the administrator.');
Of course, login.php has to be modified to accept a $_REQUEST['err'] and appropriately display it.
if(isset($user) && $user->data() != null){
if($user->data()->permissions==0){
bold('<br><br><br>Sorry. You have been banned. If you feel this is an error, please contact the administrator.');
die();
}
}
Instead of printing a message and dying, (1) log that user out and (2) redirect them to the login screen with a message:
Redirect::to($us_url_root.'users/login.php?err=Sorry. You have been banned. If you feel this is an error, please contact the administrator.');
Of course, login.php has to be modified to accept a $_REQUEST['err'] and appropriately display it.