Zeile 54 | Zeile 54 |
---|
if($mybb->input['action'] == "prune") { // User clicked no
|
if($mybb->input['action'] == "prune") { // User clicked no
|
if($mybb->input['no'])
| if($mybb->get_input('no'))
|
{ admin_redirect("index.php?module=user-banning"); }
| { admin_redirect("index.php?module=user-banning"); }
|
Zeile 114 | Zeile 114 |
---|
if($mybb->input['action'] == "lift") { // User clicked no
|
if($mybb->input['action'] == "lift") { // User clicked no
|
if($mybb->input['no'])
| if($mybb->get_input('no'))
|
{ admin_redirect("index.php?module=user-banning"); }
| { admin_redirect("index.php?module=user-banning"); }
|
Zeile 170 | Zeile 170 |
---|
$query = $db->simple_select("banned", "*", "uid='{$mybb->input['uid']}'"); $ban = $db->fetch_array($query);
|
$query = $db->simple_select("banned", "*", "uid='{$mybb->input['uid']}'"); $ban = $db->fetch_array($query);
|
$user = get_user($ban['uid']);
if(!$ban['uid'])
| if(empty($ban['uid']))
|
{ flash_message($lang->error_invalid_ban, 'error'); admin_redirect("index.php?module=user-banning"); }
|
{ flash_message($lang->error_invalid_ban, 'error'); admin_redirect("index.php?module=user-banning"); }
|
| $user = get_user($ban['uid']);
|
$plugins->run_hooks("admin_user_banning_edit");
| $plugins->run_hooks("admin_user_banning_edit");
|
Zeile 314 | Zeile 314 |
---|
$user = get_user_by_username($mybb->input['username'], $options);
// Are we searching a user?
|
$user = get_user_by_username($mybb->input['username'], $options);
// Are we searching a user?
|
if(isset($mybb->input['search']))
| if(is_array($user) && isset($mybb->input['search']))
|
{ $where_sql = 'uid=\''.(int)$user['uid'].'\''; $where_sql_full = 'WHERE b.uid=\''.(int)$user['uid'].'\''; } else {
|
{ $where_sql = 'uid=\''.(int)$user['uid'].'\''; $where_sql_full = 'WHERE b.uid=\''.(int)$user['uid'].'\''; } else {
|
if(!$user['uid'])
| if(empty($user['uid']))
|
{ $errors[] = $lang->error_invalid_username; }
| { $errors[] = $lang->error_invalid_username; }
|
Zeile 344 | Zeile 344 |
---|
{ $errors[] = $lang->error_already_banned; }
|
{ $errors[] = $lang->error_already_banned; }
|
}
| |
|
|
if($user['uid'] == $mybb->user['uid']) { $errors[] = $lang->error_ban_self;
| if($user['uid'] == $mybb->user['uid']) { $errors[] = $lang->error_ban_self; }
|
}
// No errors? Insert
| }
// No errors? Insert
|
Zeile 406 | Zeile 406 |
---|
flash_message($lang->success_banned, 'success'); admin_redirect("index.php?module=user-banning"); }
|
flash_message($lang->success_banned, 'success'); admin_redirect("index.php?module=user-banning"); }
|
} }
| } }
|
$page->output_header($lang->banned_accounts);
$page->output_nav_tabs($sub_tabs, "bans");
| $page->output_header($lang->banned_accounts);
$page->output_nav_tabs($sub_tabs, "bans");
|
Zeile 417 | Zeile 417 |
---|
$ban_count = $db->fetch_field($query, "ban_count");
$per_page = 20;
|
$ban_count = $db->fetch_field($query, "ban_count");
$per_page = 20;
|
| $mybb->input['page'] = $mybb->get_input('page', MyBB::INPUT_INT);
|
if($mybb->input['page'] > 0) {
|
if($mybb->input['page'] > 0) {
|
$current_page = $mybb->get_input('page', MyBB::INPUT_INT);
| $current_page = $mybb->input['page'];
|
$start = ($current_page-1)*$per_page; $pages = $ban_count / $per_page; $pages = ceil($pages);
| $start = ($current_page-1)*$per_page; $pages = $ban_count / $per_page; $pages = ceil($pages);
|
Zeile 434 | Zeile 435 |
---|
{ $start = 0; $current_page = 1;
|
{ $start = 0; $current_page = 1;
|
}
| }
|
$pagination = draw_admin_pagination($current_page, $per_page, $ban_count, "index.php?module=user-banning&page={page}");
| $pagination = draw_admin_pagination($current_page, $per_page, $ban_count, "index.php?module=user-banning&page={page}");
|
Zeile 444 | Zeile 445 |
---|
$page->output_inline_error($errors); }
|
$page->output_inline_error($errors); }
|
if($mybb->input['uid'] && !$mybb->input['username'])
| $mybb->input['username'] = $mybb->get_input('username'); $mybb->input['reason'] = $mybb->get_input('reason'); $mybb->input['bantime'] = $mybb->get_input('bantime');
if(isset($mybb->input['uid']) && empty($mybb->input['username']))
|
{ $user = get_user($mybb->input['uid']); $mybb->input['username'] = $user['username'];
| { $user = get_user($mybb->input['uid']); $mybb->input['username'] = $user['username'];
|