Vergleich admin/modules/forum/management.php - 1.6.12 - 1.6.18

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 19Zeile 19

if($mybb->input['action'] == "add" || $mybb->input['action'] == "edit" || $mybb->input['action'] == "copy" || $mybb->input['action'] == "permissions" || !$mybb->input['action'])
{


if($mybb->input['action'] == "add" || $mybb->input['action'] == "edit" || $mybb->input['action'] == "copy" || $mybb->input['action'] == "permissions" || !$mybb->input['action'])
{

	if(isset($mybb->input['fid']) && ($mybb->input['action'] == "management" || $mybb->input['action'] == "edit" || $mybb->input['action'] == "copy" || !$mybb->input['action']))

	if(!empty($mybb->input['fid']) && ($mybb->input['action'] == "management" || $mybb->input['action'] == "edit" || $mybb->input['action'] == "copy" || !$mybb->input['action']))

	{
$sub_tabs['view_forum'] = array(
'title' => $lang->view_forum,

	{
$sub_tabs['view_forum'] = array(
'title' => $lang->view_forum,

Zeile 236Zeile 236
	$query = $db->simple_select("usergroups", "gid, title", "gid != '1'", array('order_by' => 'title'));
while($usergroup = $db->fetch_array($query))
{

	$query = $db->simple_select("usergroups", "gid, title", "gid != '1'", array('order_by' => 'title'));
while($usergroup = $db->fetch_array($query))
{

		$usergroups[$usergroup['gid']] = $usergroup['title'];

		$usergroups[$usergroup['gid']] = htmlspecialchars_uni($usergroup['title']);

	}

$form_container = new FormContainer($lang->copy_forum);

	}

$form_container = new FormContainer($lang->copy_forum);

Zeile 447Zeile 447
			$result = $db->fetch_array($query);
$fid = $result['fid'];
$gid = $result['gid'];

			$result = $db->fetch_array($query);
$fid = $result['fid'];
$gid = $result['gid'];

 
			$forum = get_forum($fid);

		}

$field_list = array();

		}

$field_list = array();

Zeile 800Zeile 801
			foreach($mybb->input as $id => $permission)
{
if(strpos($id, 'fields_') === false)

			foreach($mybb->input as $id => $permission)
{
if(strpos($id, 'fields_') === false)

				{
continue;
}

list(, $gid) = explode('fields_', $id);

// If it isn't an array then it came from the javascript form
if(!is_array($permission))
{
$permission = explode(',', $permission);
$permission = array_flip($permission);
foreach($permission as $name => $value)
{
$permission[$name] = 1;
}

				{
continue;
}

list(, $gid) = explode('fields_', $id);

// If it isn't an array then it came from the javascript form
if(!is_array($permission))
{
$permission = explode(',', $permission);
$permission = array_flip($permission);
foreach($permission as $name => $value)
{
$permission[$name] = 1;
}

				}

foreach(array('canview','canpostthreads','canpostreplys','canpostpolls') as $name)
{
if(in_array($name, $permission) || $permission[$name])

				}

foreach(array('canview','canpostthreads','canpostreplys','canpostpolls') as $name)
{
if(in_array($name, $permission) || $permission[$name])

					{

					{

						$permissions[$name][$gid] = 1;
}
else

						$permissions[$name][$gid] = 1;
}
else

Zeile 903Zeile 904
		$forum_data['allowtratings'] = 1;
$forum_data['showinjump'] = 1;
$forum_data['usepostcounts'] = 1;

		$forum_data['allowtratings'] = 1;
$forum_data['showinjump'] = 1;
$forum_data['usepostcounts'] = 1;

	}

	}

	
$types = array(
'f' => $lang->forum,
'c' => $lang->category

	
$types = array(
'f' => $lang->forum,
'c' => $lang->category

	);

	);

	
$create_a_options_f = array(
'id' => 'forum'

	
$create_a_options_f = array(
'id' => 'forum'

	);


	);


	$create_a_options_c = array(
'id' => 'category'
);

	$create_a_options_c = array(
'id' => 'category'
);

Zeile 923Zeile 924
		$create_a_options_f['checked'] = true;
}
else

		$create_a_options_f['checked'] = true;
}
else

	{

	{

		$create_a_options_c['checked'] = true;
}


		$create_a_options_c['checked'] = true;
}


Zeile 934Zeile 935
	$form_container->output_row($lang->parent_forum." <em>*</em>", $lang->parent_forum_desc, $form->generate_forum_select('pid', $forum_data['pid'], array('id' => 'pid', 'main_option' => $lang->none)), 'pid');
$form_container->output_row($lang->display_order, "", $form->generate_text_box('disporder', $forum_data['disporder'], array('id' => 'disporder')), 'disporder');
$form_container->end();

	$form_container->output_row($lang->parent_forum." <em>*</em>", $lang->parent_forum_desc, $form->generate_forum_select('pid', $forum_data['pid'], array('id' => 'pid', 'main_option' => $lang->none)), 'pid');
$form_container->output_row($lang->display_order, "", $form->generate_text_box('disporder', $forum_data['disporder'], array('id' => 'disporder')), 'disporder');
$form_container->end();

	

	

	echo "<div id=\"additional_options_link\"><strong><a href=\"#\" onclick=\"$('additional_options_link').toggle(); $('additional_options').toggle(); return false;\">{$lang->show_additional_options}</a></strong><br /><br /></div>";
echo "<div id=\"additional_options\" style=\"display: none;\">";
$form_container = new FormContainer("<div class=\"float_right\" style=\"font-weight: normal;\"><a href=\"#\" onclick=\"$('additional_options_link').toggle(); $('additional_options').toggle(); return false;\">{$lang->hide_additional_options}</a></div>".$lang->additional_forum_options);

	echo "<div id=\"additional_options_link\"><strong><a href=\"#\" onclick=\"$('additional_options_link').toggle(); $('additional_options').toggle(); return false;\">{$lang->show_additional_options}</a></strong><br /><br /></div>";
echo "<div id=\"additional_options\" style=\"display: none;\">";
$form_container = new FormContainer("<div class=\"float_right\" style=\"font-weight: normal;\"><a href=\"#\" onclick=\"$('additional_options_link').toggle(); $('additional_options').toggle(); return false;\">{$lang->hide_additional_options}</a></div>".$lang->additional_forum_options);

Zeile 944Zeile 945
	$access_options = array(
$form->generate_check_box('active', 1, $lang->forum_is_active."<br />\n<small>{$lang->forum_is_active_desc}</small>", array('checked' => $forum_data['active'], 'id' => 'active')),
$form->generate_check_box('open', 1, $lang->forum_is_open."<br />\n<small>{$lang->forum_is_open_desc}</small>", array('checked' => $forum_data['open'], 'id' => 'open'))

	$access_options = array(
$form->generate_check_box('active', 1, $lang->forum_is_active."<br />\n<small>{$lang->forum_is_active_desc}</small>", array('checked' => $forum_data['active'], 'id' => 'active')),
$form->generate_check_box('open', 1, $lang->forum_is_open."<br />\n<small>{$lang->forum_is_open_desc}</small>", array('checked' => $forum_data['open'], 'id' => 'open'))

	);

	);

	
$form_container->output_row($lang->access_options, "", "<div class=\"forum_settings_bit\">".implode("</div><div class=\"forum_settings_bit\">", $access_options)."</div>");

	
$form_container->output_row($lang->access_options, "", "<div class=\"forum_settings_bit\">".implode("</div><div class=\"forum_settings_bit\">", $access_options)."</div>");

	

	

	$moderator_options = array(
$form->generate_check_box('modposts', 1, $lang->mod_new_posts, array('checked' => $forum_data['modposts'], 'id' => 'modposts')),
$form->generate_check_box('modthreads', 1, $lang->mod_new_threads, array('checked' => $forum_data['modthreads'], 'id' => 'modthreads')),
$form->generate_check_box('modattachments', 1, $lang->mod_new_attachments, array('checked' => $forum_data['modattachments'], 'id' => 'modattachments')),
$form->generate_check_box('mod_edit_posts', 1, $lang->mod_after_edit, array('checked' => $forum_data['mod_edit_posts'], 'id' => 'mod_edit_posts'))

	$moderator_options = array(
$form->generate_check_box('modposts', 1, $lang->mod_new_posts, array('checked' => $forum_data['modposts'], 'id' => 'modposts')),
$form->generate_check_box('modthreads', 1, $lang->mod_new_threads, array('checked' => $forum_data['modthreads'], 'id' => 'modthreads')),
$form->generate_check_box('modattachments', 1, $lang->mod_new_attachments, array('checked' => $forum_data['modattachments'], 'id' => 'modattachments')),
$form->generate_check_box('mod_edit_posts', 1, $lang->mod_after_edit, array('checked' => $forum_data['mod_edit_posts'], 'id' => 'mod_edit_posts'))

	);


	);


	$form_container->output_row($lang->moderation_options, "", "<div class=\"forum_settings_bit\">".implode("</div><div class=\"forum_settings_bit\">", $moderator_options)."</div>");

$styles = array(
'0' => $lang->use_default

	$form_container->output_row($lang->moderation_options, "", "<div class=\"forum_settings_bit\">".implode("</div><div class=\"forum_settings_bit\">", $moderator_options)."</div>");

$styles = array(
'0' => $lang->use_default

	);

	);

	
$query = $db->simple_select("themes", "tid,name", "name!='((master))' AND name!='((master-backup))'", array('order_by' => 'name'));
while($style = $db->fetch_array($query))
{
$styles[$style['tid']] = htmlspecialchars_uni($style['name']);

	
$query = $db->simple_select("themes", "tid,name", "name!='((master))' AND name!='((master-backup))'", array('order_by' => 'name'));
while($style = $db->fetch_array($query))
{
$styles[$style['tid']] = htmlspecialchars_uni($style['name']);

	}

$style_options = array(
$form->generate_check_box('overridestyle', 1, $lang->override_user_style, array('checked' => $forum_data['overridestyle'], 'id' => 'overridestyle')),
$lang->forum_specific_style."<br />\n".$form->generate_select_box('style', $styles, $forum_data['style'], array('id' => 'style'))
);

$form_container->output_row($lang->style_options, "", "<div class=\"forum_settings_bit\">".implode("</div><div class=\"forum_settings_bit\">", $style_options)."</div>");

$display_methods = array(
'0' => $lang->dont_display_rules,
'1' => $lang->display_rules_inline,
'3' => $lang->display_rules_inline_new,
'2' => $lang->display_rules_link
);

$forum_rules = array(
$lang->display_method."<br />\n".$form->generate_select_box('rulestype', $display_methods, $forum_data['rulestype'], array('checked' => $forum_data['rulestype'], 'id' => 'rulestype')),
$lang->title."<br />\n".$form->generate_text_box('rulestitle', $forum_data['rulestitle'], array('checked' => $forum_data['rulestitle'], 'id' => 'rulestitle')),
$lang->rules."<br />\n".$form->generate_text_area('rules', $forum_data['rules'], array('checked' => $forum_data['rules'], 'id' => 'rules'))
);

$form_container->output_row($lang->forum_rules, "", "<div class=\"forum_settings_bit\">".implode("</div><div class=\"forum_settings_bit\">", $forum_rules)."</div>");

$default_date_cut = array(
0 => $lang->board_default,
1 => $lang->datelimit_1day,
5 => $lang->datelimit_5days,
10 => $lang->datelimit_10days,
20 => $lang->datelimit_20days,
50 => $lang->datelimit_50days,
75 => $lang->datelimit_75days,
100 => $lang->datelimit_100days,
365 => $lang->datelimit_lastyear,
9999 => $lang->datelimit_beginning,

	}

$style_options = array(
$form->generate_check_box('overridestyle', 1, $lang->override_user_style, array('checked' => $forum_data['overridestyle'], 'id' => 'overridestyle')),
$lang->forum_specific_style."<br />\n".$form->generate_select_box('style', $styles, $forum_data['style'], array('id' => 'style'))
);

$form_container->output_row($lang->style_options, "", "<div class=\"forum_settings_bit\">".implode("</div><div class=\"forum_settings_bit\">", $style_options)."</div>");

$display_methods = array(
'0' => $lang->dont_display_rules,
'1' => $lang->display_rules_inline,
'3' => $lang->display_rules_inline_new,
'2' => $lang->display_rules_link
);

$forum_rules = array(
$lang->display_method."<br />\n".$form->generate_select_box('rulestype', $display_methods, $forum_data['rulestype'], array('checked' => $forum_data['rulestype'], 'id' => 'rulestype')),
$lang->title."<br />\n".$form->generate_text_box('rulestitle', $forum_data['rulestitle'], array('checked' => $forum_data['rulestitle'], 'id' => 'rulestitle')),
$lang->rules."<br />\n".$form->generate_text_area('rules', $forum_data['rules'], array('checked' => $forum_data['rules'], 'id' => 'rules'))
);

$form_container->output_row($lang->forum_rules, "", "<div class=\"forum_settings_bit\">".implode("</div><div class=\"forum_settings_bit\">", $forum_rules)."</div>");

$default_date_cut = array(
0 => $lang->board_default,
1 => $lang->datelimit_1day,
5 => $lang->datelimit_5days,
10 => $lang->datelimit_10days,
20 => $lang->datelimit_20days,
50 => $lang->datelimit_50days,
75 => $lang->datelimit_75days,
100 => $lang->datelimit_100days,
365 => $lang->datelimit_lastyear,
9999 => $lang->datelimit_beginning,

	);

$default_sort_by = array(

	);

$default_sort_by = array(

Zeile 1045Zeile 1046

$query = $db->simple_select("usergroups", "*", "", array("order" => "name"));
while($usergroup = $db->fetch_array($query))


$query = $db->simple_select("usergroups", "*", "", array("order" => "name"));
while($usergroup = $db->fetch_array($query))

	{

	{

		$usergroups[$usergroup['gid']] = $usergroup;
}


		$usergroups[$usergroup['gid']] = $usergroup;
}


Zeile 1114Zeile 1115
		}

if(!$perms)

		}

if(!$perms)

		{

		{

			$perms = $usergroup;
$default_checked = true;
}

			$perms = $usergroup;
$default_checked = true;
}

Zeile 1127Zeile 1128
				{
$default_checked = true;
}

				{
$default_checked = true;
}

				else
{
$default_checked = false;
}

				else
{
$default_checked = false;
}

				
if($mybb->input['permissions'][$usergroup['gid']][$forum_permission])

				
if($mybb->input['permissions'][$usergroup['gid']][$forum_permission])

				{
$perms_checked[$forum_permission] = 1;
}
else
{
$perms_checked[$forum_permission] = 0;
}
}

				{
$perms_checked[$forum_permission] = 1;
}
else
{
$perms_checked[$forum_permission] = 0;
}
}

			else
{
if($perms[$forum_permission] == 1)
{
$perms_checked[$forum_permission] = 1;

			else
{
if($perms[$forum_permission] == 1)
{
$perms_checked[$forum_permission] = 1;

				}

				}

				else
{
$perms_checked[$forum_permission] = 0;
}
}

				else
{
$perms_checked[$forum_permission] = 0;
}
}

		}

		}

		$usergroup['title'] = htmlspecialchars_uni($usergroup['title']);

if($default_checked)

		$usergroup['title'] = htmlspecialchars_uni($usergroup['title']);

if($default_checked)

Zeile 1160Zeile 1161
			$inherited_text = $lang->inherited_permission;
}
else

			$inherited_text = $lang->inherited_permission;
}
else

		{

		{

			$inherited_text = $lang->custom_permission;

			$inherited_text = $lang->custom_permission;

		}

		}

		
$form_container->output_cell("<strong>{$usergroup['title']}</strong><br />".$form->generate_check_box("default_permissions[{$usergroup['gid']}]", 1, "", array("id" => "default_permissions_{$usergroup['gid']}", "checked" => $default_checked))." <small><label for=\"default_permissions_{$usergroup['gid']}\">{$lang->permissions_use_group_default}</label></small>");


		
$form_container->output_cell("<strong>{$usergroup['title']}</strong><br />".$form->generate_check_box("default_permissions[{$usergroup['gid']}]", 1, "", array("id" => "default_permissions_{$usergroup['gid']}", "checked" => $default_checked))." <small><label for=\"default_permissions_{$usergroup['gid']}\">{$lang->permissions_use_group_default}</label></small>");


Zeile 1170Zeile 1171
		$field_select .= "<div class=\"enabled\"><ul id=\"fields_enabled_{$usergroup['gid']}\">\n";
foreach($perms_checked as $perm => $value)
{

		$field_select .= "<div class=\"enabled\"><ul id=\"fields_enabled_{$usergroup['gid']}\">\n";
foreach($perms_checked as $perm => $value)
{

			if($value == 1)
{
$field_select .= "<li id=\"field-{$perm}\">{$field_list2[$perm]}</li>";
}
}
$field_select .= "</ul></div>\n";
$field_select .= "<div class=\"disabled\"><ul id=\"fields_disabled_{$usergroup['gid']}\">\n";
foreach($perms_checked as $perm => $value)
{
if($value == 0)

			if($value == 1)
{
$field_select .= "<li id=\"field-{$perm}\">{$field_list2[$perm]}</li>";
}
}
$field_select .= "</ul></div>\n";
$field_select .= "<div class=\"disabled\"><ul id=\"fields_disabled_{$usergroup['gid']}\">\n";
foreach($perms_checked as $perm => $value)
{
if($value == 0)

			{
$field_select .= "<li id=\"field-{$perm}\">{$field_list2[$perm]}</li>";
}

			{
$field_select .= "<li id=\"field-{$perm}\">{$field_list2[$perm]}</li>";
}

Zeile 1221Zeile 1222
	// Write in our JS based field selector
echo "<script type=\"text/javascript\">\n<!--\n";
foreach($ids as $id)

	// Write in our JS based field selector
echo "<script type=\"text/javascript\">\n<!--\n";
foreach($ids as $id)

	{

	{

		echo "Event.observe(window, 'load', function(){ QuickPermEditor.init(".$id.") });\n";
}
echo "// -->\n</script>\n";

		echo "Event.observe(window, 'load', function(){ QuickPermEditor.init(".$id.") });\n";
}
echo "// -->\n</script>\n";

Zeile 1266Zeile 1267
		{
$query = $db->simple_select("forums", "*", "pid='{$mybb->input['fid']}'");
while($child = $db->fetch_array($query))

		{
$query = $db->simple_select("forums", "*", "pid='{$mybb->input['fid']}'");
while($child = $db->fetch_array($query))

			{

			{

				if($child['fid'] == $pid)
{
$errors[] = $lang->error_forum_parent_child;

				if($child['fid'] == $pid)
{
$errors[] = $lang->error_forum_parent_child;

Zeile 1288Zeile 1289
			if($db->fetch_field($query, "num_threads") > 0)
{
$errors[] = $lang->error_not_empty;

			if($db->fetch_field($query, "num_threads") > 0)
{
$errors[] = $lang->error_not_empty;

			}










			}
}

if(!empty($mybb->input['linkto']) && empty($forum_data['linkto']))
{
$query = $db->simple_select('threads', 'COUNT(tid) as num_threads', "fid = '{$fid}'", array("limit" => 1));
if($db->fetch_field($query, "num_threads") > 0)
{
$errors[] = $lang->error_forum_link_not_empty;
}

		}

		}

 


		
if(!$errors)
{

		
if(!$errors)
{

Zeile 1333Zeile 1344
			if($pid != $forum_data['pid'])
{
// Update the parentlist of this forum.

			if($pid != $forum_data['pid'])
{
// Update the parentlist of this forum.

				$db->update_query("forums", array("parentlist" => make_parent_list($fid)), "fid='{$fid}'", 1);


				$db->update_query("forums", array("parentlist" => make_parent_list($fid)), "fid='{$fid}'");


				// Rebuild the parentlist of all of the subforums of this forum
switch($db->type)

				// Rebuild the parentlist of all of the subforums of this forum
switch($db->type)

				{

				{

					case "sqlite":
case "pgsql":
$query = $db->simple_select("forums", "fid", "','||parentlist||',' LIKE '%,$fid,%'");

					case "sqlite":
case "pgsql":
$query = $db->simple_select("forums", "fid", "','||parentlist||',' LIKE '%,$fid,%'");

Zeile 1345Zeile 1356
					default:
$query = $db->simple_select("forums", "fid", "CONCAT(',',parentlist,',') LIKE '%,$fid,%'");
}

					default:
$query = $db->simple_select("forums", "fid", "CONCAT(',',parentlist,',') LIKE '%,$fid,%'");
}

				
while($child = $db->fetch_array($query))
{
$db->update_query("forums", array("parentlist" => make_parent_list($child['fid'])), "fid='{$child['fid']}'", 1);
}

				
while($child = $db->fetch_array($query))
{
$db->update_query("forums", array("parentlist" => make_parent_list($child['fid'])), "fid='{$child['fid']}'");
}

			}

$inherit = $mybb->input['default_permissions'];

			}

$inherit = $mybb->input['default_permissions'];

Zeile 1358Zeile 1369
			{
// Make sure we're only skipping inputs that don't start with "fields_" and aren't fields_default_ or fields_inherit_
if(strpos($id, 'fields_') === false || (strpos($id, 'fields_default_') !== false || strpos($id, 'fields_inherit_') !== false))

			{
// Make sure we're only skipping inputs that don't start with "fields_" and aren't fields_default_ or fields_inherit_
if(strpos($id, 'fields_') === false || (strpos($id, 'fields_default_') !== false || strpos($id, 'fields_inherit_') !== false))

				{
continue;
}

list(, $gid) = explode('fields_', $id);


				{
continue;
}

list(, $gid) = explode('fields_', $id);


				if($mybb->input['fields_default_'.$gid] == $permission && $mybb->input['fields_inherit_'.$gid] == 1)
{
$inherit[$gid] = 1;

				if($mybb->input['fields_default_'.$gid] == $permission && $mybb->input['fields_inherit_'.$gid] == 1)
{
$inherit[$gid] = 1;

Zeile 1843Zeile 1854
		$mod = $db->fetch_array($query);

$db->delete_query("moderators", "mid='{$mid}'");

		$mod = $db->fetch_array($query);

$db->delete_query("moderators", "mid='{$mid}'");

		$query = $db->simple_select("moderators", "*", "id='{$mod['id']}' AND isgroup='0'");
if($db->num_rows($query) == 0)
{
$updatequery = array(
"usergroup" => "2"
);
$db->update_query("users", $updatequery, "uid='{$mod['id']}' AND usergroup != '4' AND usergroup != '3'");
}

 
		$cache->update_moderators();

$plugins->run_hooks("admin_forum_management_deletemod_commit");

		$cache->update_moderators();

$plugins->run_hooks("admin_forum_management_deletemod_commit");

Zeile 1869Zeile 1872
		
flash_message($lang->success_moderator_deleted, 'success');
admin_redirect("index.php?module=forum-management&fid={$fid}#tab_moderators");

		
flash_message($lang->success_moderator_deleted, 'success');
admin_redirect("index.php?module=forum-management&fid={$fid}#tab_moderators");

	}

	}

	else
{
$page->output_confirm_action("index.php?module=forum-management&amp;action=deletemod&amp;fid={$mod['fid']}&amp;uid={$mod['uid']}", $lang->confirm_moderator_deletion);

	else
{
$page->output_confirm_action("index.php?module=forum-management&amp;action=deletemod&amp;fid={$mod['fid']}&amp;uid={$mod['uid']}", $lang->confirm_moderator_deletion);

Zeile 1887Zeile 1890
	if(!$forum['fid'])
{
flash_message($lang->error_invalid_forum, 'error');

	if(!$forum['fid'])
{
flash_message($lang->error_invalid_forum, 'error');

		admin_redirect("index.php?module=forum-management");

		admin_redirect("index.php?module=forum-management");

	}

// User clicked no

	}

// User clicked no

Zeile 1906Zeile 1909
		
// Delete the forum
$db->delete_query("forums", "fid='$fid'");

		
// Delete the forum
$db->delete_query("forums", "fid='$fid'");

		

		

		switch($db->type)
{
case "pgsql":

		switch($db->type)
{
case "pgsql":

Zeile 1925Zeile 1928
			$stats['unapprovedposts'] += $forum['unapprovedposts'];
$stats['threads'] += $forum['threads'];
$stats['unapprovedthreads'] += $forum['unapprovedthreads'];

			$stats['unapprovedposts'] += $forum['unapprovedposts'];
$stats['threads'] += $forum['threads'];
$stats['unapprovedthreads'] += $forum['unapprovedthreads'];

		}

/**
* This slab of code pulls out the moderators for this forum,
* checks if they moderate any other forums, and if they don't
* it moves them back to the registered usergroup
*/

$query = $db->simple_select("moderators", "*", "fid='$fid' AND isgroup='0'");
while($mod = $db->fetch_array($query))
{
$moderators[$mod['id']] = $mod['id'];
}

if(is_array($moderators))
{
$mod_list = implode(",", $moderators);
$query = $db->simple_select("moderators", "*", "fid != '$fid' AND id IN ($mod_list) AND isgroup='0'");
while($mod = $db->fetch_array($query))
{
unset($moderators[$mod['id']]);
}
}

if(is_array($moderators))
{
$mod_list = implode(",", $moderators);
if($mod_list)
{
$updatequery = array(
"usergroup" => "2"
);
$db->update_query("users", $updatequery, "uid IN ($mod_list) AND usergroup='6'");
}

 
		}

switch($db->type)

		}

switch($db->type)

Zeile 2524Zeile 2493

foreach($usergroups as $group)
{


foreach($usergroups as $group)
{

			$modgroups[$group['gid']] = $lang->usergroup." ".$group['gid'].": ".$group['title'];

			$modgroups[$group['gid']] = $lang->usergroup." ".$group['gid'].": ".htmlspecialchars_uni($group['title']);

		}

if(!isset($mybb->input['usergroup']))

		}

if(!isset($mybb->input['usergroup']))