Vergleich admin/modules/user/groups.php - 1.6.5 - 1.6.16

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 6Zeile 6
 * Website: http://mybb.com
* License: http://mybb.com/about/license
*

 * Website: http://mybb.com
* License: http://mybb.com/about/license
*

 * $Id: groups.php 5648 2011-11-09 08:48:00Z Tomm $

 * $Id$

 */

 */

 



// Array of usergroup permission fields and their default values.
$usergroup_permissions = array(
"isbannedgroup" => 0,

// Array of usergroup permission fields and their default values.
$usergroup_permissions = array(
"isbannedgroup" => 0,

Zeile 34Zeile 34
	"pmquota" => 100,
"maxpmrecipients" => 5,
"cansendemail" => 1,

	"pmquota" => 100,
"maxpmrecipients" => 5,
"cansendemail" => 1,

 
	"cansendemailoverride" => 0,

	"maxemails" => 4,
"canviewmemberlist" => 1,
"canviewcalendar" => 1,

	"maxemails" => 4,
"canviewmemberlist" => 1,
"canviewcalendar" => 1,

Zeile 80Zeile 81
$page->add_breadcrumb_item($lang->user_groups, "index.php?module=user-groups");

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

$page->add_breadcrumb_item($lang->user_groups, "index.php?module=user-groups");

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

{

{

	$sub_tabs['manage_groups'] = array(
'title' => $lang->manage_user_groups,
'link' => "index.php?module=user-groups",
'description' => $lang->manage_user_groups_desc

	$sub_tabs['manage_groups'] = array(
'title' => $lang->manage_user_groups,
'link' => "index.php?module=user-groups",
'description' => $lang->manage_user_groups_desc

	);

	);

	$sub_tabs['add_group'] = array(
'title' => $lang->add_user_group,
'link' => "index.php?module=user-groups&action=add",

	$sub_tabs['add_group'] = array(
'title' => $lang->add_user_group,
'link' => "index.php?module=user-groups&action=add",

Zeile 98Zeile 99
if($mybb->input['action'] == "export")
{
$plugins->run_hooks("admin_user_groups_export_start");

if($mybb->input['action'] == "export")
{
$plugins->run_hooks("admin_user_groups_export_start");

	



	// Log admin action
log_admin_action();


	// Log admin action
log_admin_action();


Zeile 116Zeile 117
		$xml .= "\t\t<usergroup>\n";
foreach($usergroup as $key => $value)
{

		$xml .= "\t\t<usergroup>\n";
foreach($usergroup as $key => $value)
{

 
			$value = str_replace(']]>', ']]]]><![CDATA[>', $value);

			$xml .= "\t\t\t<{$key}><![CDATA[{$value}]]></{$key}>\n";
}
$xml .= "\t\t</usergroup>\n";

			$xml .= "\t\t\t<{$key}><![CDATA[{$value}]]></{$key}>\n";
}
$xml .= "\t\t</usergroup>\n";

Zeile 129Zeile 131
	header("Content-type: unknown/unknown");
header("Pragma: no-cache");
header("Expires: 0");

	header("Content-type: unknown/unknown");
header("Pragma: no-cache");
header("Expires: 0");

	



	$plugins->run_hooks("admin_user_groups_export_end");

	$plugins->run_hooks("admin_user_groups_export_end");

	



	echo $xml;

	echo $xml;

	exit;	

	exit;

}

if($mybb->input['action'] == "approve_join_request")
{
$plugins->run_hooks("admin_user_groups_approve_join_request");

}

if($mybb->input['action'] == "approve_join_request")
{
$plugins->run_hooks("admin_user_groups_approve_join_request");

	



	$query = $db->simple_select("joinrequests", "*", "rid='".$mybb->input['rid']."'");
$request = $db->fetch_array($query);

	$query = $db->simple_select("joinrequests", "*", "rid='".$mybb->input['rid']."'");
$request = $db->fetch_array($query);

	



	if(!$request['rid'])
{
flash_message($lang->error_invalid_join_request, 'error');
admin_redirect("index.php?module=user-groups");
}

	if(!$request['rid'])
{
flash_message($lang->error_invalid_join_request, 'error');
admin_redirect("index.php?module=user-groups");
}

	








if(!verify_post_check($mybb->input['my_post_key']))
{
flash_message($lang->invalid_post_verify_key2, 'error');
admin_redirect("index.php?module=user-groups&action=join_requests&gid={$request['gid']}");
}


	// Add the user to the group
join_usergroup($request['uid'], $request['gid']);

	// Add the user to the group
join_usergroup($request['uid'], $request['gid']);

	



	// Delete the join request
$db->delete_query("joinrequests", "rid='{$request['rid']}'");

	// Delete the join request
$db->delete_query("joinrequests", "rid='{$request['rid']}'");

	



	flash_message($lang->success_join_request_approved, "success");
admin_redirect("index.php?module=user-groups&action=join_requests&gid={$request['gid']}");
}

	flash_message($lang->success_join_request_approved, "success");
admin_redirect("index.php?module=user-groups&action=join_requests&gid={$request['gid']}");
}

Zeile 162Zeile 170
if($mybb->input['action'] == "deny_join_request")
{
$plugins->run_hooks("admin_user_groups_deny_join_request");

if($mybb->input['action'] == "deny_join_request")
{
$plugins->run_hooks("admin_user_groups_deny_join_request");

	



	$query = $db->simple_select("joinrequests", "*", "rid='".$mybb->input['rid']."'");
$request = $db->fetch_array($query);


	$query = $db->simple_select("joinrequests", "*", "rid='".$mybb->input['rid']."'");
$request = $db->fetch_array($query);


Zeile 170Zeile 178
	{
flash_message($lang->error_invalid_join_request, 'error');
admin_redirect("index.php?module=user-groups");

	{
flash_message($lang->error_invalid_join_request, 'error');
admin_redirect("index.php?module=user-groups");

 
	}

if(!verify_post_check($mybb->input['my_post_key']))
{
flash_message($lang->invalid_post_verify_key2, 'error');
admin_redirect("index.php?module=user-groups&action=join_requests&gid={$request['gid']}");

	}

// Delete the join request
$db->delete_query("joinrequests", "rid='{$request['rid']}'");

	}

// Delete the join request
$db->delete_query("joinrequests", "rid='{$request['rid']}'");





	flash_message($lang->success_join_request_denied, "success");
admin_redirect("index.php?module=user-groups&action=join_requests&gid={$request['gid']}");
}

	flash_message($lang->success_join_request_denied, "success");
admin_redirect("index.php?module=user-groups&action=join_requests&gid={$request['gid']}");
}





if($mybb->input['action'] == "join_requests")
{
$plugins->run_hooks("admin_user_groups_join_requests_start");

if($mybb->input['action'] == "join_requests")
{
$plugins->run_hooks("admin_user_groups_join_requests_start");

	



	$query = $db->simple_select("usergroups", "*", "gid='".intval($mybb->input['gid'])."'");
$group = $db->fetch_array($query);

	$query = $db->simple_select("usergroups", "*", "gid='".intval($mybb->input['gid'])."'");
$group = $db->fetch_array($query);

	



	if(!$group['gid'] || $group['type'] != 4)

	if(!$group['gid'] || $group['type'] != 4)

	{

	{

		flash_message($lang->error_invalid_user_group, 'error');
admin_redirect("index.php?module=user-groups");
}

		flash_message($lang->error_invalid_user_group, 'error');
admin_redirect("index.php?module=user-groups");
}

	



	if($mybb->request_method == "post" && is_array($mybb->input['users']))

	if($mybb->request_method == "post" && is_array($mybb->input['users']))

	{		

	{

		$uid_in = implode(",", array_map('intval', $mybb->input['users']));

		$uid_in = implode(",", array_map('intval', $mybb->input['users']));

		



		if(isset($mybb->input['approve']))
{
foreach($mybb->input['users'] as $uid)

		if(isset($mybb->input['approve']))
{
foreach($mybb->input['users'] as $uid)

Zeile 206Zeile 220
			// Log admin action
log_admin_action("approve", $group['title'], $group['gid']);
$message = $lang->success_selected_requests_approved;

			// Log admin action
log_admin_action("approve", $group['title'], $group['gid']);
$message = $lang->success_selected_requests_approved;

		}

		}

		else
{
// Log admin action
log_admin_action("deny", $group['title'], $group['gid']);
$message = $lang->success_selected_requests_denied;
}

		else
{
// Log admin action
log_admin_action("deny", $group['title'], $group['gid']);
$message = $lang->success_selected_requests_denied;
}

		



		$plugins->run_hooks("admin_user_groups_join_requests_commit");

		$plugins->run_hooks("admin_user_groups_join_requests_commit");

		



		// Go through and delete the join requests from the database
$db->delete_query("joinrequests", "uid IN ({$uid_in}) AND gid='{$group['gid']}'");

		// Go through and delete the join requests from the database
$db->delete_query("joinrequests", "uid IN ({$uid_in}) AND gid='{$group['gid']}'");





		flash_message($message, 'success');
admin_redirect("index.php?module=user-groups&action=join_requests&gid={$group['gid']}");
}

		flash_message($message, 'success');
admin_redirect("index.php?module=user-groups&action=join_requests&gid={$group['gid']}");
}

	



	$page->add_breadcrumb_item($lang->join_requests_for." {$group['title']}");
$page->output_header($lang->join_requests_for." {$group['title']}");

	$page->add_breadcrumb_item($lang->join_requests_for." {$group['title']}");
$page->output_header($lang->join_requests_for." {$group['title']}");

	



	$sub_tabs = array();
$sub_tabs['join_requests'] = array(
'title' => $lang->group_join_requests,
'link' => "index.php?module=user-groups&action=join_requests&gid={$group['gid']}",
'description' => $lang->group_join_requests_desc
);

	$sub_tabs = array();
$sub_tabs['join_requests'] = array(
'title' => $lang->group_join_requests,
'link' => "index.php?module=user-groups&action=join_requests&gid={$group['gid']}",
'description' => $lang->group_join_requests_desc
);

		



	$page->output_nav_tabs($sub_tabs, 'join_requests');

	$page->output_nav_tabs($sub_tabs, 'join_requests');

	



	$query = $db->simple_select("joinrequests", "COUNT(*) AS num_requests", "gid='{$group['gid']}'");
$num_requests = $db->fetch_field($query, "num_requests");

	$query = $db->simple_select("joinrequests", "COUNT(*) AS num_requests", "gid='{$group['gid']}'");
$num_requests = $db->fetch_field($query, "num_requests");





	$per_page = 20;

if($mybb->input['page'] > 0)

	$per_page = 20;

if($mybb->input['page'] > 0)

Zeile 264Zeile 278
	{
$pagination = draw_admin_pagination($page, $per_page, $num_requests, "index.php?module=user-groups&amp;action=join_requests&gid={$group['gid']}");
echo $pagination;

	{
$pagination = draw_admin_pagination($page, $per_page, $num_requests, "index.php?module=user-groups&amp;action=join_requests&gid={$group['gid']}");
echo $pagination;

	}	

	}


$form = new Form("index.php?module=user-groups&amp;action=join_requests&gid={$group['gid']}", "post");
$table = new Table;


$form = new Form("index.php?module=user-groups&amp;action=join_requests&gid={$group['gid']}", "post");
$table = new Table;

Zeile 272Zeile 286
	$table->construct_header($lang->users);
$table->construct_header($lang->reason);
$table->construct_header($lang->date_requested, array("class" => 'align_center', "width" => 200));

	$table->construct_header($lang->users);
$table->construct_header($lang->reason);
$table->construct_header($lang->date_requested, array("class" => 'align_center', "width" => 200));

	$table->construct_header($lang->controls, array("class" => "align_center", "colspan" => 2, "width" => 200));

	$table->construct_header($lang->controls, array("class" => "align_center", "width" => 200));


$query = $db->query("
SELECT j.*, u.username


$query = $db->query("
SELECT j.*, u.username

Zeile 282Zeile 296
		ORDER BY dateline ASC
LIMIT {$start}, {$per_page}
");

		ORDER BY dateline ASC
LIMIT {$start}, {$per_page}
");

 


	while($request = $db->fetch_array($query))

	while($request = $db->fetch_array($query))

	{

	{

		$table->construct_cell($form->generate_check_box("users[]", $request['uid'], ""));
$table->construct_cell("<strong>".build_profile_link($request['username'], $request['uid'], "_blank")."</strong>");
$table->construct_cell(htmlspecialchars_uni($request['reason']));
$table->construct_cell(my_date($mybb->settings['dateformat'].", ".$mybb->settings['timeformat'], $request['dateline']), array('class' => 'align_center'));

		$table->construct_cell($form->generate_check_box("users[]", $request['uid'], ""));
$table->construct_cell("<strong>".build_profile_link($request['username'], $request['uid'], "_blank")."</strong>");
$table->construct_cell(htmlspecialchars_uni($request['reason']));
$table->construct_cell(my_date($mybb->settings['dateformat'].", ".$mybb->settings['timeformat'], $request['dateline']), array('class' => 'align_center'));

		$table->construct_cell("<a href=\"index.php?module=user-groups&action=approve_join_request&amp;rid={$request['rid']}\">{$lang->approve}</a>", array("class" => "align_center"));
$table->construct_cell("<a href=\"index.php?module=user-groups&action=deny_join_request&amp;rid={$request['rid']}\">{$lang->deny}</a>", array("class" => "align_center"));
$table->construct_row();






$popup = new PopupMenu("join_{$request['rid']}", $lang->options);
$popup->add_item($lang->approve, "index.php?module=user-groups&action=approve_join_request&amp;rid={$request['rid']}&amp;my_post_key={$mybb->post_code}");
$popup->add_item($lang->deny, "index.php?module=user-groups&action=deny_join_request&amp;rid={$request['rid']}&amp;my_post_key={$mybb->post_code}");

$table->construct_cell($popup->fetch(), array('class' => "align_center"));
$table->construct_row();

	}

	}

	



	if($table->num_rows() == 0)
{
$table->construct_cell($lang->no_join_requests, array("colspan" => 6));
$table->construct_row();

	if($table->num_rows() == 0)
{
$table->construct_cell($lang->no_join_requests, array("colspan" => 6));
$table->construct_row();

	}

	}


$table->output($lang->join_requests_for." {$group['title']}");
echo $pagination;


$table->output($lang->join_requests_for." {$group['title']}");
echo $pagination;

Zeile 306Zeile 325
	$buttons[] = $form->generate_submit_button($lang->deny_selected_requests, array('name' => 'deny'));
$form->output_submit_wrapper($buttons);
$form->end();

	$buttons[] = $form->generate_submit_button($lang->deny_selected_requests, array('name' => 'deny'));
$form->output_submit_wrapper($buttons);
$form->end();

	
$page->output_footer();


$page->output_footer();

}
if($mybb->input['action'] == "add_leader" && $mybb->request_method == "post")
{
$plugins->run_hooks("admin_user_groups_add_leader");

}
if($mybb->input['action'] == "add_leader" && $mybb->request_method == "post")
{
$plugins->run_hooks("admin_user_groups_add_leader");

	



	$query = $db->simple_select("usergroups", "*", "gid='".intval($mybb->input['gid'])."'");
$group = $db->fetch_array($query);


	$query = $db->simple_select("usergroups", "*", "gid='".intval($mybb->input['gid'])."'");
$group = $db->fetch_array($query);


Zeile 321Zeile 340
		flash_message($lang->error_invalid_user_group, 'error');
admin_redirect("index.php?module=user-group");
}

		flash_message($lang->error_invalid_user_group, 'error');
admin_redirect("index.php?module=user-group");
}

		



	$query = $db->simple_select("users", "uid, username", "LOWER(username)='".$db->escape_string(my_strtolower($mybb->input['username']))."'");
$user = $db->fetch_array($query);
if(!$user['uid'])

	$query = $db->simple_select("users", "uid, username", "LOWER(username)='".$db->escape_string(my_strtolower($mybb->input['username']))."'");
$user = $db->fetch_array($query);
if(!$user['uid'])

	{

	{

		$errors[] = $lang->error_invalid_username;

		$errors[] = $lang->error_invalid_username;

	}

	}

	else
{
// Is this user already a leader of this group?

	else
{
// Is this user already a leader of this group?

Zeile 338Zeile 357
			$errors[] = $lang->error_already_leader;
}
}

			$errors[] = $lang->error_already_leader;
}
}

	



	// No errors, insert
if(!$errors)
{

	// No errors, insert
if(!$errors)
{

Zeile 348Zeile 367
			"canmanagemembers" => intval($mybb->input['canmanagemembers']),
"canmanagerequests" => intval($mybb->input['canmanagerequests'])
);

			"canmanagemembers" => intval($mybb->input['canmanagemembers']),
"canmanagerequests" => intval($mybb->input['canmanagerequests'])
);

		



		$plugins->run_hooks("admin_user_groups_add_leader_commit");

		$plugins->run_hooks("admin_user_groups_add_leader_commit");

		
$db->insert_query("groupleaders", $new_leader);


$db->insert_query("groupleaders", $new_leader);


$cache->update_groupleaders();


$cache->update_groupleaders();

		



		// Log admin action
log_admin_action($user['uid'], $mybb->input['username'], $group['gid'], $group['title']);


		// Log admin action
log_admin_action($user['uid'], $mybb->input['username'], $group['gid'], $group['title']);


Zeile 365Zeile 384
	{
// Errors, show leaders page
$mybb->input['action'] = "leaders";

	{
// Errors, show leaders page
$mybb->input['action'] = "leaders";

	}
}


	}
}


// Show a listing of group leaders
if($mybb->input['action'] == "leaders")
{
$plugins->run_hooks("admin_user_groups_leaders");

// Show a listing of group leaders
if($mybb->input['action'] == "leaders")
{
$plugins->run_hooks("admin_user_groups_leaders");

	



	$query = $db->simple_select("usergroups", "*", "gid='".intval($mybb->input['gid'])."'");
$group = $db->fetch_array($query);


	$query = $db->simple_select("usergroups", "*", "gid='".intval($mybb->input['gid'])."'");
$group = $db->fetch_array($query);


Zeile 384Zeile 403

$page->add_breadcrumb_item($lang->group_leaders_for." {$group['title']}");
$page->output_header($lang->group_leaders_for." {$group['title']}");


$page->add_breadcrumb_item($lang->group_leaders_for." {$group['title']}");
$page->output_header($lang->group_leaders_for." {$group['title']}");

	



	$sub_tabs = array();
$sub_tabs['group_leaders'] = array(
'title' => $lang->manage_group_leaders,
'link' => "index.php?module=user-groups&action=leaders&gid={$group['gid']}",
'description' => $lang->manage_group_leaders_desc
);

	$sub_tabs = array();
$sub_tabs['group_leaders'] = array(
'title' => $lang->manage_group_leaders,
'link' => "index.php?module=user-groups&action=leaders&gid={$group['gid']}",
'description' => $lang->manage_group_leaders_desc
);

		



	$page->output_nav_tabs($sub_tabs, 'group_leaders');

$table = new Table;

	$page->output_nav_tabs($sub_tabs, 'group_leaders');

$table = new Table;

Zeile 418Zeile 437
		{
$canmanagemembers = $lang->no;
}

		{
$canmanagemembers = $lang->no;
}

			



		if($leader['canmanagerequests'])
{
$canmanagerequests = $lang->yes;

		if($leader['canmanagerequests'])
{
$canmanagerequests = $lang->yes;

Zeile 427Zeile 446
		{
$canmanagerequests = $lang->no;
}

		{
$canmanagerequests = $lang->no;
}

		



		$table->construct_cell("<strong>".build_profile_link($leader['username'], $leader['uid'], "_blank")."</strong>");
$table->construct_cell($canmanagemembers, array("class" => "align_center"));
$table->construct_cell($canmanagerequests, array("class" => "align_center"));
$table->construct_cell("<a href=\"index.php?module=user-groups&amp;action=edit_leader&lid={$leader['lid']}\">{$lang->edit}</a>", array("class" => "align_center"));
$table->construct_cell("<a href=\"index.php?module=user-groups&amp;action=delete_leader&amp;lid={$leader['lid']}&amp;my_post_key={$mybb->post_code}\" onclick=\"return AdminCP.deleteConfirmation(this, '{$lang->confirm_group_leader_deletion}')\">{$lang->delete}</a>", array("width" => 100, "class" => "align_center"));

		$table->construct_cell("<strong>".build_profile_link($leader['username'], $leader['uid'], "_blank")."</strong>");
$table->construct_cell($canmanagemembers, array("class" => "align_center"));
$table->construct_cell($canmanagerequests, array("class" => "align_center"));
$table->construct_cell("<a href=\"index.php?module=user-groups&amp;action=edit_leader&lid={$leader['lid']}\">{$lang->edit}</a>", array("class" => "align_center"));
$table->construct_cell("<a href=\"index.php?module=user-groups&amp;action=delete_leader&amp;lid={$leader['lid']}&amp;my_post_key={$mybb->post_code}\" onclick=\"return AdminCP.deleteConfirmation(this, '{$lang->confirm_group_leader_deletion}')\">{$lang->delete}</a>", array("width" => 100, "class" => "align_center"));

		$table->construct_row();

		$table->construct_row();

	}

	}

	



	if($table->num_rows() == 0)
{
$table->construct_cell($lang->no_assigned_leaders, array("colspan" => 5));
$table->construct_row();

	if($table->num_rows() == 0)
{
$table->construct_cell($lang->no_assigned_leaders, array("colspan" => 5));
$table->construct_row();

	}


	}


	$table->output($lang->group_leaders_for." {$group['title']}");

	$table->output($lang->group_leaders_for." {$group['title']}");

	



	$form = new Form("index.php?module=user-groups&amp;action=add_leader&amp;gid={$group['gid']}", "post");

	$form = new Form("index.php?module=user-groups&amp;action=add_leader&amp;gid={$group['gid']}", "post");

	



	if($errors)

	if($errors)

	{

	{

		$page->output_inline_error($errors);
}
else

		$page->output_inline_error($errors);
}
else

Zeile 457Zeile 476
			"canmanagerequests" => 1
);
}

			"canmanagerequests" => 1
);
}

	



	$form_container = new FormContainer($lang->add_group_leader." {$group['title']}");
$form_container->output_row($lang->username." <em>*</em>", "", $form->generate_text_box('username', $mybb->input['username'], array('id' => 'username')), 'username');
$form_container->output_row($lang->can_manage_group_members, $lang->can_manage_group_members_desc, $form->generate_yes_no_radio('canmanagemembers', $mybb->input['canmanagemembers']));
$form_container->output_row($lang->can_manage_group_join_requests, $lang->can_manage_group_join_requests_desc, $form->generate_yes_no_radio('canmanagerequests', $mybb->input['canmanagerequests']));
$buttons[] = $form->generate_submit_button($lang->save_group_leader);

	$form_container = new FormContainer($lang->add_group_leader." {$group['title']}");
$form_container->output_row($lang->username." <em>*</em>", "", $form->generate_text_box('username', $mybb->input['username'], array('id' => 'username')), 'username');
$form_container->output_row($lang->can_manage_group_members, $lang->can_manage_group_members_desc, $form->generate_yes_no_radio('canmanagemembers', $mybb->input['canmanagemembers']));
$form_container->output_row($lang->can_manage_group_join_requests, $lang->can_manage_group_join_requests_desc, $form->generate_yes_no_radio('canmanagerequests', $mybb->input['canmanagerequests']));
$buttons[] = $form->generate_submit_button($lang->save_group_leader);

	



	$form_container->end();
$form->output_submit_wrapper($buttons);
$form->end();

	$form_container->end();
$form->output_submit_wrapper($buttons);
$form->end();

	
$page->output_footer();


$page->output_footer();

}


}






if($mybb->input['action'] == "delete_leader")
{
$plugins->run_hooks("admin_user_groups_delete_leader");

if($mybb->input['action'] == "delete_leader")
{
$plugins->run_hooks("admin_user_groups_delete_leader");

	



	$query = $db->query("
SELECT l.*, u.username
FROM ".TABLE_PREFIX."groupleaders l
INNER JOIN ".TABLE_PREFIX."users u ON (u.uid=l.uid)
WHERE l.lid='".intval($mybb->input['lid'])."'");
$leader = $db->fetch_array($query);

	$query = $db->query("
SELECT l.*, u.username
FROM ".TABLE_PREFIX."groupleaders l
INNER JOIN ".TABLE_PREFIX."users u ON (u.uid=l.uid)
WHERE l.lid='".intval($mybb->input['lid'])."'");
$leader = $db->fetch_array($query);

	



	if(!$leader['lid'])

	if(!$leader['lid'])

	{

	{

		flash_message($lang->error_invalid_group_leader, 'error');

		flash_message($lang->error_invalid_group_leader, 'error');

		admin_redirect("index.php?module=user-groups");		
}


		admin_redirect("index.php?module=user-groups");
}


	$query = $db->simple_select("usergroups", "*", "gid='{$leader['gid']}'");

	$query = $db->simple_select("usergroups", "*", "gid='{$leader['gid']}'");

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


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


	// User clicked no
if($mybb->input['no'])

	// User clicked no
if($mybb->input['no'])

	{

	{

		admin_redirect("index.php?module=user-groups");
}

if($mybb->request_method == "post")

		admin_redirect("index.php?module=user-groups");
}

if($mybb->request_method == "post")

	{		

	{

		$plugins->run_hooks("admin_user_groups_delete_leader_commit");

		$plugins->run_hooks("admin_user_groups_delete_leader_commit");

		



		// Delete the leader
$db->delete_query("groupleaders", "lid='{$leader['lid']}'");

		// Delete the leader
$db->delete_query("groupleaders", "lid='{$leader['lid']}'");

		



		$cache->update_groupleaders();

		$cache->update_groupleaders();

		



		// Log admin action
log_admin_action($leader['lid'], $leader['username'], $group['gid'], $group['title']);


		// Log admin action
log_admin_action($leader['lid'], $leader['username'], $group['gid'], $group['title']);


Zeile 522Zeile 541
if($mybb->input['action'] == "edit_leader")
{
$plugins->run_hooks("admin_user_groups_edit_leader");

if($mybb->input['action'] == "edit_leader")
{
$plugins->run_hooks("admin_user_groups_edit_leader");

	



	$query = $db->query("
SELECT l.*, u.username
FROM ".TABLE_PREFIX."groupleaders l

	$query = $db->query("
SELECT l.*, u.username
FROM ".TABLE_PREFIX."groupleaders l

Zeile 530Zeile 549
		WHERE l.lid='".intval($mybb->input['lid'])."'
");
$leader = $db->fetch_array($query);

		WHERE l.lid='".intval($mybb->input['lid'])."'
");
$leader = $db->fetch_array($query);





	if(!$leader['lid'])
{
flash_message($lang->error_invalid_group_leader, 'error');

	if(!$leader['lid'])
{
flash_message($lang->error_invalid_group_leader, 'error');

		admin_redirect("index.php?module=user-groups");		

		admin_redirect("index.php?module=user-groups");

	}

$query = $db->simple_select("usergroups", "*", "gid='{$leader['gid']}'");
$group = $db->fetch_array($query);

	}

$query = $db->simple_select("usergroups", "*", "gid='{$leader['gid']}'");
$group = $db->fetch_array($query);

		



	if($mybb->request_method == "post")
{
$updated_leader = array(
"canmanagemembers" => intval($mybb->input['canmanagemembers']),
"canmanagerequests" => intval($mybb->input['canmanagerequests'])
);

	if($mybb->request_method == "post")
{
$updated_leader = array(
"canmanagemembers" => intval($mybb->input['canmanagemembers']),
"canmanagerequests" => intval($mybb->input['canmanagerequests'])
);

		



		$plugins->run_hooks("admin_user_groups_edit_leader_commit");
$db->update_query("groupleaders", $updated_leader, "lid={$leader['lid']}");

		$plugins->run_hooks("admin_user_groups_edit_leader_commit");
$db->update_query("groupleaders", $updated_leader, "lid={$leader['lid']}");

		



		$cache->update_groupleaders();

		$cache->update_groupleaders();

		



		// Log admin action
log_admin_action($leader['lid'], $leader['username'], $group['gid'], $group['title']);

		// Log admin action
log_admin_action($leader['lid'], $leader['username'], $group['gid'], $group['title']);





		flash_message($lang->success_group_leader_updated, 'success');

		flash_message($lang->success_group_leader_updated, 'success');

		admin_redirect("index.php?module=user-groups&action=leaders&gid={$group['gid']}");		

		admin_redirect("index.php?module=user-groups&action=leaders&gid={$group['gid']}");

	}

	}

	



	if(!$errors)
{
$mybb->input = $leader;
}

	if(!$errors)
{
$mybb->input = $leader;
}

	



	$page->add_breadcrumb_item($lang->group_leaders_for." {$group['title']}", "index.php?module=user-groups&action=leaders&gid={$group['gid']}");
$page->add_breadcrumb_item($lang->edit_leader." {$leader['username']}");

	$page->add_breadcrumb_item($lang->group_leaders_for." {$group['title']}", "index.php?module=user-groups&action=leaders&gid={$group['gid']}");
$page->add_breadcrumb_item($lang->edit_leader." {$leader['username']}");

	



	$page->output_header($lang->edit_group_leader);

	$page->output_header($lang->edit_group_leader);

	



	$sub_tabs = array();
$sub_tabs['group_leaders'] = array(
'title' => $lang->edit_group_leader,
'link' => "index.php?module=user-groups&action=edit_leader&lid={$leader['lid']}",
'description' => $lang->edit_group_leader_desc
);

	$sub_tabs = array();
$sub_tabs['group_leaders'] = array(
'title' => $lang->edit_group_leader,
'link' => "index.php?module=user-groups&action=edit_leader&lid={$leader['lid']}",
'description' => $lang->edit_group_leader_desc
);

		



	$page->output_nav_tabs($sub_tabs, 'group_leaders');


	$page->output_nav_tabs($sub_tabs, 'group_leaders');


	$form = new Form("index.php?module=user-groups&amp;action=edit_leader&lid={$leader['lid']}'", "post");


	$form = new Form("index.php?module=user-groups&amp;action=edit_leader&amp;lid={$leader['lid']}", "post");


	$form_container = new FormContainer($lang->edit_group_leader);
$form_container->output_row($lang->username." <em>*</em>", "", $leader['username']);

	$form_container = new FormContainer($lang->edit_group_leader);
$form_container->output_row($lang->username." <em>*</em>", "", $leader['username']);

	



	$form_container->output_row($lang->can_manage_group_members, $lang->can_manage_group_members_desc, $form->generate_yes_no_radio('canmanagemembers', $mybb->input['canmanagemembers']));
$form_container->output_row($lang->can_manage_group_join_requests, $lang->can_manage_group_join_requests_desc, $form->generate_yes_no_radio('canmanagerequests', $mybb->input['canmanagerequests']));
$buttons[] = $form->generate_submit_button($lang->save_group_leader);

	$form_container->output_row($lang->can_manage_group_members, $lang->can_manage_group_members_desc, $form->generate_yes_no_radio('canmanagemembers', $mybb->input['canmanagemembers']));
$form_container->output_row($lang->can_manage_group_join_requests, $lang->can_manage_group_join_requests_desc, $form->generate_yes_no_radio('canmanagerequests', $mybb->input['canmanagerequests']));
$buttons[] = $form->generate_submit_button($lang->save_group_leader);

	



	$form_container->end();
$form->output_submit_wrapper($buttons);
$form->end();

	$form_container->end();
$form->output_submit_wrapper($buttons);
$form->end();

	
$page->output_footer();
}


$page->output_footer();
}


if($mybb->input['action'] == "add")
{
$plugins->run_hooks("admin_user_groups_add");


if($mybb->input['action'] == "add")
{
$plugins->run_hooks("admin_user_groups_add");

	



	if($mybb->request_method == "post")
{
if(!trim($mybb->input['title']))

	if($mybb->request_method == "post")
{
if(!trim($mybb->input['title']))

		{

		{

			$errors[] = $lang->error_missing_title;

			$errors[] = $lang->error_missing_title;

		}


		}


		if(my_strpos($mybb->input['namestyle'], "{username}") === false)
{
$errors[] = $lang->error_missing_namestyle_username;

		if(my_strpos($mybb->input['namestyle'], "{username}") === false)
{
$errors[] = $lang->error_missing_namestyle_username;

Zeile 613Zeile 632
		if(!$errors)
{
if($mybb->input['stars'] < 1)

		if(!$errors)
{
if($mybb->input['stars'] < 1)

			{

			{

				$mybb->input['stars'] = 0;

				$mybb->input['stars'] = 0;

			}


			}


			if(!$mybb->input['starimage'])
{
$mybb->input['starimage'] = "images/star.gif";
}

			if(!$mybb->input['starimage'])
{
$mybb->input['starimage'] = "images/star.gif";
}

			



			$new_usergroup = array(
"type" => 2,
"title" => $db->escape_string($mybb->input['title']),

			$new_usergroup = array(
"type" => 2,
"title" => $db->escape_string($mybb->input['title']),

Zeile 632Zeile 651
				"starimage" => $db->escape_string($mybb->input['starimage']),
"disporder" => 0
);

				"starimage" => $db->escape_string($mybb->input['starimage']),
"disporder" => 0
);

			



			// Set default permissions
if($mybb->input['copyfrom'] == 0)
{

			// Set default permissions
if($mybb->input['copyfrom'] == 0)
{

Zeile 648Zeile 667
					$new_usergroup[$field] = $existing_usergroup[$field];
}
}

					$new_usergroup[$field] = $existing_usergroup[$field];
}
}

			



			$plugins->run_hooks("admin_user_groups_add_commit");

			$plugins->run_hooks("admin_user_groups_add_commit");

			



			$gid = $db->insert_query("usergroups", $new_usergroup);

			$gid = $db->insert_query("usergroups", $new_usergroup);

			



			// Are we copying permissions? If so, copy all forum permissions too
if($mybb->input['copyfrom'] > 0)
{

			// Are we copying permissions? If so, copy all forum permissions too
if($mybb->input['copyfrom'] > 0)
{

Zeile 671Zeile 690

// Log admin action
log_admin_action($gid, $mybb->input['title']);


// Log admin action
log_admin_action($gid, $mybb->input['title']);

			



			flash_message($lang->success_group_created, 'success');
admin_redirect("index.php?module=user-groups&action=edit&gid={$gid}");
}

			flash_message($lang->success_group_created, 'success');
admin_redirect("index.php?module=user-groups&action=edit&gid={$gid}");
}

Zeile 679Zeile 698

$page->add_breadcrumb_item($lang->add_user_group);
$page->output_header($lang->add_user_group);


$page->add_breadcrumb_item($lang->add_user_group);
$page->output_header($lang->add_user_group);

	



	$page->output_nav_tabs($sub_tabs, 'add_group');
$form = new Form("index.php?module=user-groups&amp;action=add", "post");

	$page->output_nav_tabs($sub_tabs, 'add_group');
$form = new Form("index.php?module=user-groups&amp;action=add", "post");

	



	if($errors)

	if($errors)

	{

	{

		$page->output_inline_error($errors);
}
else

		$page->output_inline_error($errors);
}
else

Zeile 692Zeile 711
		$mybb->input = array(
"namestyle" => "{username}"
);

		$mybb->input = array(
"namestyle" => "{username}"
);

	}


	}


	$form_container = new FormContainer($lang->add_user_group);
$form_container->output_row($lang->title." <em>*</em>", "", $form->generate_text_box('title', $mybb->input['title'], array('id' => 'title')), 'title');
$form_container->output_row($lang->short_description, "", $form->generate_text_box('description', $mybb->input['description'], array('id' => 'description')), 'description');

	$form_container = new FormContainer($lang->add_user_group);
$form_container->output_row($lang->title." <em>*</em>", "", $form->generate_text_box('title', $mybb->input['title'], array('id' => 'title')), 'title');
$form_container->output_row($lang->short_description, "", $form->generate_text_box('description', $mybb->input['description'], array('id' => 'description')), 'description');

Zeile 719Zeile 738
if($mybb->input['action'] == "edit")
{
$plugins->run_hooks("admin_user_groups_edit");

if($mybb->input['action'] == "edit")
{
$plugins->run_hooks("admin_user_groups_edit");

	



	$query = $db->simple_select("usergroups", "*", "gid='".intval($mybb->input['gid'])."'");
$usergroup = $db->fetch_array($query);

if(!$usergroup['gid'])

	$query = $db->simple_select("usergroups", "*", "gid='".intval($mybb->input['gid'])."'");
$usergroup = $db->fetch_array($query);

if(!$usergroup['gid'])

	{

	{

		flash_message($lang->error_invalid_user_group, 'error');
admin_redirect("index.php?module=user-group");
}

		flash_message($lang->error_invalid_user_group, 'error');
admin_redirect("index.php?module=user-group");
}

Zeile 732Zeile 751
	if($mybb->request_method == "post")
{
if(!trim($mybb->input['title']))

	if($mybb->request_method == "post")
{
if(!trim($mybb->input['title']))

		{

		{

			$errors[] = $lang->error_missing_title;

			$errors[] = $lang->error_missing_title;

		}


		}


		if(my_strpos($mybb->input['namestyle'], "{username}") === false)

		if(my_strpos($mybb->input['namestyle'], "{username}") === false)

		{

		{

			$errors[] = $lang->error_missing_namestyle_username;

			$errors[] = $lang->error_missing_namestyle_username;

 
		}
else
{
if(preg_match("#<((m[^a])|(b[^diloru>])|(s[^aemptu>]))(\s*[^>]*)>#si", $mybb->input['namestyle']))
{
$errors[] = $lang->error_disallowed_namestyle_username;
$mybb->input['namestyle'] = $usergroup['namestyle'];
}

		}

if(!$errors)

		}

if(!$errors)

Zeile 801Zeile 828
				"pmquota" => intval($mybb->input['pmquota']),
"maxpmrecipients" => intval($mybb->input['maxpmrecipients']),
"cansendemail" => intval($mybb->input['cansendemail']),

				"pmquota" => intval($mybb->input['pmquota']),
"maxpmrecipients" => intval($mybb->input['maxpmrecipients']),
"cansendemail" => intval($mybb->input['cansendemail']),

				"maxemails" => intval($mybb->input['maxemails']),		


				"cansendemailoverride" => intval($mybb->input['cansendemailoverride']),
"maxemails" => intval($mybb->input['maxemails']),

				"canviewmemberlist" => intval($mybb->input['canviewmemberlist']),
"canviewcalendar" => intval($mybb->input['canviewcalendar']),
"canaddevents" => intval($mybb->input['canaddevents']),

				"canviewmemberlist" => intval($mybb->input['canviewmemberlist']),
"canviewcalendar" => intval($mybb->input['canviewcalendar']),
"canaddevents" => intval($mybb->input['canaddevents']),

Zeile 841Zeile 869
			{
$updated_group['candisplaygroup'] = intval($mybb->input['candisplaygroup']);
}

			{
$updated_group['candisplaygroup'] = intval($mybb->input['candisplaygroup']);
}

			



			$plugins->run_hooks("admin_user_groups_edit_commit");

			$plugins->run_hooks("admin_user_groups_edit_commit");





			$db->update_query("usergroups", $updated_group, "gid='{$usergroup['gid']}'");

// Update the caches

			$db->update_query("usergroups", $updated_group, "gid='{$usergroup['gid']}'");

// Update the caches

			$cache->update_usergroups();

			$cache->update_usergroups();

			$cache->update_forumpermissions();


			$cache->update_forumpermissions();






			// Log admin action
log_admin_action($usergroup['gid'], $mybb->input['title']);

			// Log admin action
log_admin_action($usergroup['gid'], $mybb->input['title']);

			



			flash_message($lang->success_group_updated, 'success');
admin_redirect("index.php?module=user-groups");
}
}

			flash_message($lang->success_group_updated, 'success');
admin_redirect("index.php?module=user-groups");
}
}

	



	$page->add_breadcrumb_item($lang->edit_user_group);
$page->output_header($lang->edit_user_group);

	$page->add_breadcrumb_item($lang->edit_user_group);
$page->output_header($lang->edit_user_group);

	
$sub_tabs = array();


$sub_tabs = array();

	$sub_tabs['edit_group'] = array(
'title' => $lang->edit_user_group,
'description' => $lang->edit_user_group_desc

	$sub_tabs['edit_group'] = array(
'title' => $lang->edit_user_group,
'description' => $lang->edit_user_group_desc

	);


	);


	$form = new Form("index.php?module=user-groups&amp;action=edit&amp;gid={$usergroup['gid']}", "post");

	$form = new Form("index.php?module=user-groups&amp;action=edit&amp;gid={$usergroup['gid']}", "post");





	$page->output_nav_tabs($sub_tabs, 'edit_group');

// If we have any error messages, show them
if($errors)

	$page->output_nav_tabs($sub_tabs, 'edit_group');

// If we have any error messages, show them
if($errors)

	{

	{

		$page->output_inline_error($errors);
}
else
{
if($usergroup['type'] == "3")

		$page->output_inline_error($errors);
}
else
{
if($usergroup['type'] == "3")

		{
$usergroup['joinable'] = 1;
$usergroup['moderate'] = 0;

		{
$usergroup['joinable'] = 1;
$usergroup['moderate'] = 0;

		}
elseif($usergroup['type'] == "4")
{
$usergroup['joinable'] = 1;
$usergroup['moderate'] = 1;

		}
elseif($usergroup['type'] == "4")
{
$usergroup['joinable'] = 1;
$usergroup['moderate'] = 1;

		}

		}

		else
{
$usergroup['joinable'] = 0;
$usergroup['moderate'] = 0;

		else
{
$usergroup['joinable'] = 0;
$usergroup['moderate'] = 0;

		}		

		}

		$mybb->input = $usergroup;

		$mybb->input = $usergroup;

	}	

	}

	$tabs = array(
"general" => $lang->general,
"forums_posts" => $lang->forums_posts,
"users_permissions" => $lang->users_permissions,

	$tabs = array(
"general" => $lang->general,
"forums_posts" => $lang->forums_posts,
"users_permissions" => $lang->users_permissions,

		"misc" => $lang->misc		
);

		"misc" => $lang->misc
);

	$tabs = $plugins->run_hooks("admin_user_groups_edit_graph_tabs", $tabs);
$page->output_tab_control($tabs);

	$tabs = $plugins->run_hooks("admin_user_groups_edit_graph_tabs", $tabs);
$page->output_tab_control($tabs);

	
echo "<div id=\"tab_general\">";


echo "<div id=\"tab_general\">";

	$form_container = new FormContainer($lang->general);
$form_container->output_row($lang->title." <em>*</em>", "", $form->generate_text_box('title', $mybb->input['title'], array('id' => 'title')), 'title');
$form_container->output_row($lang->short_description, "", $form->generate_text_box('description', $mybb->input['description'], array('id' => 'description')), 'description');

	$form_container = new FormContainer($lang->general);
$form_container->output_row($lang->title." <em>*</em>", "", $form->generate_text_box('title', $mybb->input['title'], array('id' => 'title')), 'title');
$form_container->output_row($lang->short_description, "", $form->generate_text_box('description', $mybb->input['description'], array('id' => 'description')), 'description');

Zeile 924Zeile 952
		$general_options[] = $form->generate_check_box("showforumteam", 1, $lang->forum_team, array("checked" => $mybb->input['showforumteam']));
}
$general_options[] = $form->generate_check_box("isbannedgroup", 1, $lang->is_banned_group, array("checked" => $mybb->input['isbannedgroup']));

		$general_options[] = $form->generate_check_box("showforumteam", 1, $lang->forum_team, array("checked" => $mybb->input['showforumteam']));
}
$general_options[] = $form->generate_check_box("isbannedgroup", 1, $lang->is_banned_group, array("checked" => $mybb->input['isbannedgroup']));

	



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

if($usergroup['type'] != 1)

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

if($usergroup['type'] != 1)

Zeile 936Zeile 964
			);
$form_container->output_row($lang->publicly_joinable_options, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $public_options)."</div>");
}

			);
$form_container->output_row($lang->publicly_joinable_options, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $public_options)."</div>");
}

		



	$admin_options = array(
$form->generate_check_box("issupermod", 1, $lang->is_super_mod, array("checked" => $mybb->input['issupermod'])),
$form->generate_check_box("canmodcp", 1, $lang->can_access_mod_cp, array("checked" => $mybb->input['canmodcp'])),
$form->generate_check_box("cancp", 1, $lang->can_access_admin_cp, array("checked" => $mybb->input['cancp']))
);
$form_container->output_row($lang->moderation_administration_options, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $admin_options)."</div>");

	$admin_options = array(
$form->generate_check_box("issupermod", 1, $lang->is_super_mod, array("checked" => $mybb->input['issupermod'])),
$form->generate_check_box("canmodcp", 1, $lang->can_access_mod_cp, array("checked" => $mybb->input['canmodcp'])),
$form->generate_check_box("cancp", 1, $lang->can_access_admin_cp, array("checked" => $mybb->input['cancp']))
);
$form_container->output_row($lang->moderation_administration_options, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $admin_options)."</div>");





	$form_container->end();
echo "</div>";

	$form_container->end();
echo "</div>";

	



	//
// FORUMS AND POSTS
//

	//
// FORUMS AND POSTS
//

	echo "<div id=\"tab_forums_posts\">";	

	echo "<div id=\"tab_forums_posts\">";

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

$viewing_options = array(

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

$viewing_options = array(

Zeile 960Zeile 988
		$form->generate_check_box("canviewprofiles", 1, $lang->can_view_profiles, array("checked" => $mybb->input['canviewprofiles'])),
$form->generate_check_box("candlattachments", 1, $lang->can_download_attachments, array("checked" => $mybb->input['candlattachments'])),
);

		$form->generate_check_box("canviewprofiles", 1, $lang->can_view_profiles, array("checked" => $mybb->input['canviewprofiles'])),
$form->generate_check_box("candlattachments", 1, $lang->can_download_attachments, array("checked" => $mybb->input['candlattachments'])),
);

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


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


	$posting_options = array(
$form->generate_check_box("canpostthreads", 1, $lang->can_post_threads, array("checked" => $mybb->input['canpostthreads'])),
$form->generate_check_box("canpostreplys", 1, $lang->can_post_replies, array("checked" => $mybb->input['canpostreplys'])),
$form->generate_check_box("canratethreads", 1, $lang->can_rate_threads, array("checked" => $mybb->input['canratethreads']))
);
$form_container->output_row($lang->posting_rating_options, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $posting_options)."</div>");

	$posting_options = array(
$form->generate_check_box("canpostthreads", 1, $lang->can_post_threads, array("checked" => $mybb->input['canpostthreads'])),
$form->generate_check_box("canpostreplys", 1, $lang->can_post_replies, array("checked" => $mybb->input['canpostreplys'])),
$form->generate_check_box("canratethreads", 1, $lang->can_rate_threads, array("checked" => $mybb->input['canratethreads']))
);
$form_container->output_row($lang->posting_rating_options, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $posting_options)."</div>");

	



	$poll_options = array(
$form->generate_check_box("canpostpolls", 1, $lang->can_post_polls, array("checked" => $mybb->input['canpostpolls'])),
$form->generate_check_box("canvotepolls", 1, $lang->can_vote_polls, array("checked" => $mybb->input['canvotepolls'])),
$form->generate_check_box("canundovotes", 1, $lang->can_undo_votes, array("checked" => $mybb->input['canundovotes']))
);

	$poll_options = array(
$form->generate_check_box("canpostpolls", 1, $lang->can_post_polls, array("checked" => $mybb->input['canpostpolls'])),
$form->generate_check_box("canvotepolls", 1, $lang->can_vote_polls, array("checked" => $mybb->input['canvotepolls'])),
$form->generate_check_box("canundovotes", 1, $lang->can_undo_votes, array("checked" => $mybb->input['canundovotes']))
);

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

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


$attachment_options = array(
$form->generate_check_box("canpostattachments", 1, $lang->can_post_attachments, array("checked" => $mybb->input['canpostattachments'])),
"{$lang->attach_quota}<br /><small class=\"input\">{$lang->attach_quota_desc}</small><br />".$form->generate_text_box('attachquota', $mybb->input['attachquota'], array('id' => 'attachquota', 'class' => 'field50')). "KB"
);


$attachment_options = array(
$form->generate_check_box("canpostattachments", 1, $lang->can_post_attachments, array("checked" => $mybb->input['canpostattachments'])),
"{$lang->attach_quota}<br /><small class=\"input\">{$lang->attach_quota_desc}</small><br />".$form->generate_text_box('attachquota', $mybb->input['attachquota'], array('id' => 'attachquota', 'class' => 'field50')). "KB"
);

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

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


$editing_options = array(
$form->generate_check_box("caneditposts", 1, $lang->can_edit_posts, array("checked" => $mybb->input['caneditposts'])),


$editing_options = array(
$form->generate_check_box("caneditposts", 1, $lang->can_edit_posts, array("checked" => $mybb->input['caneditposts'])),

Zeile 989Zeile 1017
		$form->generate_check_box("caneditattachments", 1, $lang->can_edit_attachments, array("checked" => $mybb->input['caneditattachments']))
);
$form_container->output_row($lang->editing_deleting_options, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $editing_options)."</div>");

		$form->generate_check_box("caneditattachments", 1, $lang->can_edit_attachments, array("checked" => $mybb->input['caneditattachments']))
);
$form_container->output_row($lang->editing_deleting_options, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $editing_options)."</div>");

	



	$form_container->end();

	$form_container->end();

	echo "</div>";	

	echo "</div>";


//
// USERS AND PERMISSIONS
//


//
// USERS AND PERMISSIONS
//

	echo "<div id=\"tab_users_permissions\">";	

	echo "<div id=\"tab_users_permissions\">";

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

$account_options = array(

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

$account_options = array(

Zeile 1008Zeile 1036
		$form->generate_check_box("signofollow", 1, $lang->uses_no_follow, array("checked" => $mybb->input['signofollow'])),
"{$lang->required_posts}<br /><small class=\"input\">{$lang->required_posts_desc}</small><br />".$form->generate_text_box('canusesigxposts', $mybb->input['canusesigxposts'], array('id' => 'canusesigxposts', 'class' => 'field50'))
);

		$form->generate_check_box("signofollow", 1, $lang->uses_no_follow, array("checked" => $mybb->input['signofollow'])),
"{$lang->required_posts}<br /><small class=\"input\">{$lang->required_posts_desc}</small><br />".$form->generate_text_box('canusesigxposts', $mybb->input['canusesigxposts'], array('id' => 'canusesigxposts', 'class' => 'field50'))
);

	$form_container->output_row($lang->account_management, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $account_options)."</div>");	

	$form_container->output_row($lang->account_management, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $account_options)."</div>");


$reputation_options = array(
$form->generate_check_box("usereputationsystem", 1, $lang->show_reputations, array("checked" => $mybb->input['usereputationsystem'])),
$form->generate_check_box("cangivereputations", 1, $lang->can_give_reputation, array("checked" => $mybb->input['cangivereputations'])),
"{$lang->points_to_award_take}<br /><small class=\"input\">{$lang->points_to_award_take_desc}</small><br />".$form->generate_text_box('reputationpower', $mybb->input['reputationpower'], array('id' => 'reputationpower', 'class' => 'field50')),
"{$lang->max_reputations_perthread}<br /><small class=\"input\">{$lang->max_reputations_perthread_desc}</small><br />".$form->generate_text_box('maxreputationsperthread', $mybb->input['maxreputationsperthread'], array('id' => 'maxreputationsperthread', 'class' => 'field50')),


$reputation_options = array(
$form->generate_check_box("usereputationsystem", 1, $lang->show_reputations, array("checked" => $mybb->input['usereputationsystem'])),
$form->generate_check_box("cangivereputations", 1, $lang->can_give_reputation, array("checked" => $mybb->input['cangivereputations'])),
"{$lang->points_to_award_take}<br /><small class=\"input\">{$lang->points_to_award_take_desc}</small><br />".$form->generate_text_box('reputationpower', $mybb->input['reputationpower'], array('id' => 'reputationpower', 'class' => 'field50')),
"{$lang->max_reputations_perthread}<br /><small class=\"input\">{$lang->max_reputations_perthread_desc}</small><br />".$form->generate_text_box('maxreputationsperthread', $mybb->input['maxreputationsperthread'], array('id' => 'maxreputationsperthread', 'class' => 'field50')),

		"{$lang->max_reputations_daily}<br /><small class=\"input\">{$lang->max_reputations_daily_desc}</small><br />".$form->generate_text_box('maxreputationsday', $mybb->input['maxreputationsday'], array('id' => 'maxreputationsday', 'class' => 'field50'))	

		"{$lang->max_reputations_daily}<br /><small class=\"input\">{$lang->max_reputations_daily_desc}</small><br />".$form->generate_text_box('maxreputationsday', $mybb->input['maxreputationsday'], array('id' => 'maxreputationsday', 'class' => 'field50'))

	);
$form_container->output_row($lang->reputation_system, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $reputation_options)."</div>");


	);
$form_container->output_row($lang->reputation_system, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $reputation_options)."</div>");


Zeile 1036Zeile 1064
		"{$lang->max_recipients}<br /><small>{$lang->max_recipients_desc}</small><br />".$form->generate_text_box('maxpmrecipients', $mybb->input['maxpmrecipients'], array('id' => 'maxpmrecipients', 'class' => 'field50'))
);
$form_container->output_row($lang->private_messaging, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $pm_options)."</div>");

		"{$lang->max_recipients}<br /><small>{$lang->max_recipients_desc}</small><br />".$form->generate_text_box('maxpmrecipients', $mybb->input['maxpmrecipients'], array('id' => 'maxpmrecipients', 'class' => 'field50'))
);
$form_container->output_row($lang->private_messaging, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $pm_options)."</div>");

	



	$form_container->end();
echo "</div>";

//
// MISC
//

	$form_container->end();
echo "</div>";

//
// MISC
//

	echo "<div id=\"tab_misc\">";	

	echo "<div id=\"tab_misc\">";

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

$calendar_options = array(

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

$calendar_options = array(

Zeile 1065Zeile 1093
		$form->generate_check_box("canviewmemberlist", 1, $lang->can_view_member_list, array("checked" => $mybb->input['canviewmemberlist'])),
$form->generate_check_box("showinbirthdaylist", 1, $lang->show_in_birthday_list, array("checked" => $mybb->input['showinbirthdaylist'])),
$form->generate_check_box("cansendemail", 1, $lang->can_email_users, array("checked" => $mybb->input['cansendemail'])),

		$form->generate_check_box("canviewmemberlist", 1, $lang->can_view_member_list, array("checked" => $mybb->input['canviewmemberlist'])),
$form->generate_check_box("showinbirthdaylist", 1, $lang->show_in_birthday_list, array("checked" => $mybb->input['showinbirthdaylist'])),
$form->generate_check_box("cansendemail", 1, $lang->can_email_users, array("checked" => $mybb->input['cansendemail'])),

 
		$form->generate_check_box("cansendemailoverride", 1, $lang->can_email_users_override, array("checked" => $mybb->input['cansendemailoverride'])),

		"{$lang->max_emails_per_day}<br /><small class=\"input\">{$lang->max_emails_per_day_desc}</small><br />".$form->generate_text_box('maxemails', $mybb->input['maxemails'], array('id' => 'maxemails', 'class' => 'field50'))
);
$form_container->output_row($lang->misc, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $misc_options)."</div>");

$form_container->end();
echo "</div>";

		"{$lang->max_emails_per_day}<br /><small class=\"input\">{$lang->max_emails_per_day_desc}</small><br />".$form->generate_text_box('maxemails', $mybb->input['maxemails'], array('id' => 'maxemails', 'class' => 'field50'))
);
$form_container->output_row($lang->misc, "", "<div class=\"group_settings_bit\">".implode("</div><div class=\"group_settings_bit\">", $misc_options)."</div>");

$form_container->end();
echo "</div>";

	



	$plugins->run_hooks("admin_user_groups_edit_graph");

	$plugins->run_hooks("admin_user_groups_edit_graph");

	



	$buttons[] = $form->generate_submit_button($lang->save_user_group);
$form->output_submit_wrapper($buttons);

	$buttons[] = $form->generate_submit_button($lang->save_user_group);
$form->output_submit_wrapper($buttons);





	$form->end();

	$form->end();

	$page->output_footer();	

	$page->output_footer();

}

if($mybb->input['action'] == "delete")
{
$plugins->run_hooks("admin_user_groups_delete");

}

if($mybb->input['action'] == "delete")
{
$plugins->run_hooks("admin_user_groups_delete");

	



	$query = $db->simple_select("usergroups", "*", "gid='".intval($mybb->input['gid'])."'");
$usergroup = $db->fetch_array($query);

if(!$usergroup['gid'])
{
flash_message($lang->error_invalid_user_group, 'error');

	$query = $db->simple_select("usergroups", "*", "gid='".intval($mybb->input['gid'])."'");
$usergroup = $db->fetch_array($query);

if(!$usergroup['gid'])
{
flash_message($lang->error_invalid_user_group, 'error');

		admin_redirect("index.php?module=user-groups");
}

		admin_redirect("index.php?module=user-groups");
}

	if($usergroup['type'] == 1)
{
flash_message($lang->error_default_group_delete, 'error');

	if($usergroup['type'] == 1)
{
flash_message($lang->error_default_group_delete, 'error');

Zeile 1113Zeile 1142

$updated_users = array("displaygroup" => "usergroup");
$plugins->run_hooks("admin_user_groups_delete_commit");


$updated_users = array("displaygroup" => "usergroup");
$plugins->run_hooks("admin_user_groups_delete_commit");

		



		$db->update_query("users", $updated_users, "displaygroup='{$usergroup['gid']}'", "", true); // No quotes = displaygroup=usergroup

		$db->update_query("users", $updated_users, "displaygroup='{$usergroup['gid']}'", "", true); // No quotes = displaygroup=usergroup

		



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

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

Zeile 1128Zeile 1157
		while($user = $db->fetch_array($query))
{
leave_usergroup($user['uid'], $usergroup['gid']);

		while($user = $db->fetch_array($query))
{
leave_usergroup($user['uid'], $usergroup['gid']);

		}

		}


$db->delete_query("groupleaders", "gid='{$usergroup['gid']}'");
$db->delete_query("usergroups", "gid='{$usergroup['gid']}'");


$db->delete_query("groupleaders", "gid='{$usergroup['gid']}'");
$db->delete_query("usergroups", "gid='{$usergroup['gid']}'");

		



		$cache->update_groupleaders();
$cache->update_moderators();
$cache->update_usergroups();
$cache->update_forumpermissions();

		$cache->update_groupleaders();
$cache->update_moderators();
$cache->update_usergroups();
$cache->update_forumpermissions();

		



		// Log admin action
log_admin_action($usergroup['gid'], $usergroup['title']);


		// Log admin action
log_admin_action($usergroup['gid'], $usergroup['title']);


Zeile 1147Zeile 1176
	else
{
$page->output_confirm_action("index.php?module=user-groups&amp;action=delete&amp;gid={$usergroup['gid']}", $lang->confirm_group_deletion);

	else
{
$page->output_confirm_action("index.php?module=user-groups&amp;action=delete&amp;gid={$usergroup['gid']}", $lang->confirm_group_deletion);

	}

	}

}

}





if($mybb->input['action'] == "disporder" && $mybb->request_method == "post")
{
$plugins->run_hooks("admin_user_groups_disporder");

if($mybb->input['action'] == "disporder" && $mybb->request_method == "post")
{
$plugins->run_hooks("admin_user_groups_disporder");

	



	foreach($mybb->input['disporder'] as $gid=>$order)
{
$gid = intval($gid);

	foreach($mybb->input['disporder'] as $gid=>$order)
{
$gid = intval($gid);

Zeile 1169Zeile 1198

// Log admin action
log_admin_action();


// Log admin action
log_admin_action();

	
$plugins->run_hooks("admin_user_groups_disporder_commit");


$plugins->run_hooks("admin_user_groups_disporder_commit");


flash_message($lang->success_group_disporders_updated, 'success');
admin_redirect("index.php?module=user-groups");


flash_message($lang->success_group_disporders_updated, 'success');
admin_redirect("index.php?module=user-groups");

Zeile 1179Zeile 1208
if(!$mybb->input['action'])
{
$plugins->run_hooks("admin_user_groups_start");

if(!$mybb->input['action'])
{
$plugins->run_hooks("admin_user_groups_start");

	



	if($mybb->request_method == "post")
{
if(!empty($mybb->input['disporder']))

	if($mybb->request_method == "post")
{
if(!empty($mybb->input['disporder']))

		{

		{

			foreach($mybb->input['disporder'] as $gid => $order)
{
$db->update_query("usergroups", array('disporder' => intval($order)), "gid='".intval($gid)."'");
}

			foreach($mybb->input['disporder'] as $gid => $order)
{
$db->update_query("usergroups", array('disporder' => intval($order)), "gid='".intval($gid)."'");
}

			



			$plugins->run_hooks("admin_user_groups_start_commit");

			$plugins->run_hooks("admin_user_groups_start_commit");

			



			$cache->update_usergroups();

			$cache->update_usergroups();

		



			flash_message($lang->success_groups_disporder_updated, 'success');
admin_redirect("index.php?module=user-groups");
}
}

			flash_message($lang->success_groups_disporder_updated, 'success');
admin_redirect("index.php?module=user-groups");
}
}

	



	$page->output_header($lang->manage_user_groups);
$page->output_nav_tabs($sub_tabs, 'manage_groups');

	$page->output_header($lang->manage_user_groups);
$page->output_nav_tabs($sub_tabs, 'manage_groups');

	



	$form = new Form("index.php?module=user-groups", "post", "groups");

	$form = new Form("index.php?module=user-groups", "post", "groups");

	



	$query = $db->query("
SELECT g.gid, COUNT(u.uid) AS users
FROM ".TABLE_PREFIX."users u
LEFT JOIN ".TABLE_PREFIX."usergroups g ON (g.gid=u.usergroup)

	$query = $db->query("
SELECT g.gid, COUNT(u.uid) AS users
FROM ".TABLE_PREFIX."users u
LEFT JOIN ".TABLE_PREFIX."usergroups g ON (g.gid=u.usergroup)

		GROUP BY g.gid
");

		GROUP BY g.gid
");

	while($groupcount = $db->fetch_array($query))
{
$primaryusers[$groupcount['gid']] = $groupcount['users'];

	while($groupcount = $db->fetch_array($query))
{
$primaryusers[$groupcount['gid']] = $groupcount['users'];

Zeile 1245Zeile 1274
		GROUP BY g.gid
");
while($joinrequest = $db->fetch_array($query))

		GROUP BY g.gid
");
while($joinrequest = $db->fetch_array($query))

	{

	{

		$joinrequests[$joinrequest['gid']] = $joinrequest['users'];

		$joinrequests[$joinrequest['gid']] = $joinrequest['users'];

	}


	}


	// Fetch group leaders
$leaders = array();
$query = $db->query("

	// Fetch group leaders
$leaders = array();
$query = $db->query("

Zeile 1261Zeile 1290
	{
$leaders[$leader['gid']][] = build_profile_link($leader['username'], $leader['uid'], "_blank");
}

	{
$leaders[$leader['gid']][] = build_profile_link($leader['username'], $leader['uid'], "_blank");
}

	



	$form_container = new FormContainer($lang->user_groups);
$form_container->output_row_header($lang->group);
$form_container->output_row_header($lang->number_of_users, array("class" => "align_center", 'width' => '75'));
$form_container->output_row_header($lang->order, array("class" => "align_center", 'width' => '5%'));
$form_container->output_row_header($lang->controls, array("class" => "align_center"));

	$form_container = new FormContainer($lang->user_groups);
$form_container->output_row_header($lang->group);
$form_container->output_row_header($lang->number_of_users, array("class" => "align_center", 'width' => '75'));
$form_container->output_row_header($lang->order, array("class" => "align_center", 'width' => '5%'));
$form_container->output_row_header($lang->controls, array("class" => "align_center"));

	



	$query = $db->simple_select("usergroups", "*", "", array('order_by' => 'disporder'));
while($usergroup = $db->fetch_array($query))
{
if($usergroup['type'] > 1)

	$query = $db->simple_select("usergroups", "*", "", array('order_by' => 'disporder'));
while($usergroup = $db->fetch_array($query))
{
if($usergroup['type'] > 1)

		{

		{

			$icon = "<img src=\"styles/default/images/icons/custom.gif\" alt=\"{$lang->custom_user_group}\" style=\"vertical-align: middle;\" />";
}
else
{
$icon = "<img src=\"styles/default/images/icons/default.gif\" alt=\"{$lang->default_user_group}\" style=\"vertical-align: middle;\" />";
}

			$icon = "<img src=\"styles/default/images/icons/custom.gif\" alt=\"{$lang->custom_user_group}\" style=\"vertical-align: middle;\" />";
}
else
{
$icon = "<img src=\"styles/default/images/icons/default.gif\" alt=\"{$lang->default_user_group}\" style=\"vertical-align: middle;\" />";
}

		



		$leaders_list = '';
if(isset($leaders[$usergroup['gid']]))
{
$leaders_list = "<br />{$lang->group_leaders}: ".implode(", ", $leaders[$usergroup['gid']]);
}

		$leaders_list = '';
if(isset($leaders[$usergroup['gid']]))
{
$leaders_list = "<br />{$lang->group_leaders}: ".implode(", ", $leaders[$usergroup['gid']]);
}

			



		$join_requests = '';
if($joinrequests[$usergroup['gid']] > 1)

		$join_requests = '';
if($joinrequests[$usergroup['gid']] > 1)

		{

		{

			$join_requests = " <small><a href=\"index.php?module=user-groups&amp;action=join_requests&amp;gid={$usergroup['gid']}\"><span style=\"color: red;\">({$joinrequests[$usergroup['gid']]} {$lang->outstanding_join_request})</span></a></small>";
}
else if($joinrequests[$usergroup['gid']] == 1)
{

			$join_requests = " <small><a href=\"index.php?module=user-groups&amp;action=join_requests&amp;gid={$usergroup['gid']}\"><span style=\"color: red;\">({$joinrequests[$usergroup['gid']]} {$lang->outstanding_join_request})</span></a></small>";
}
else if($joinrequests[$usergroup['gid']] == 1)
{

			$join_requests = " <small><a href=\"index.php?module=user-groups&amp;action=join_requests&amp;gid={$usergroup['gid']}\"><span style=\"color: red;\">({$joinrequests[$usergroup['gid']]} {$lang->outstanding_join_request})</span></a></small>";			

			$join_requests = " <small><a href=\"index.php?module=user-groups&amp;action=join_requests&amp;gid={$usergroup['gid']}\"><span style=\"color: red;\">({$joinrequests[$usergroup['gid']]} {$lang->outstanding_join_request})</span></a></small>";

		}

		}

		



		$form_container->output_cell("<div class=\"float_right\">{$icon}</div><div><strong><a href=\"index.php?module=user-groups&amp;action=edit&amp;gid={$usergroup['gid']}\">{$usergroup['title']}</a></strong>{$join_requests}<br /><small>{$usergroup['description']}{$leaders_list}</small></div>");

		$form_container->output_cell("<div class=\"float_right\">{$icon}</div><div><strong><a href=\"index.php?module=user-groups&amp;action=edit&amp;gid={$usergroup['gid']}\">{$usergroup['title']}</a></strong>{$join_requests}<br /><small>{$usergroup['description']}{$leaders_list}</small></div>");

		



		if(!$primaryusers[$usergroup['gid']])
{
$primaryusers[$usergroup['gid']] = 0;

		if(!$primaryusers[$usergroup['gid']])
{
$primaryusers[$usergroup['gid']] = 0;

Zeile 1306Zeile 1335
		$numusers += $secondaryusers[$usergroup['gid']];

$form_container->output_cell(my_number_format($numusers), array("class" => "align_center"));

		$numusers += $secondaryusers[$usergroup['gid']];

$form_container->output_cell(my_number_format($numusers), array("class" => "align_center"));

		



		if($usergroup['showforumteam'] == 1)
{
$form_container->output_cell("<input type=\"text\" name=\"disporder[{$usergroup['gid']}]\" value=\"{$usergroup['disporder']}\" class=\"text_input align_center\" style=\"width: 80%;\" />", array("class" => "align_center"));

		if($usergroup['showforumteam'] == 1)
{
$form_container->output_cell("<input type=\"text\" name=\"disporder[{$usergroup['gid']}]\" value=\"{$usergroup['disporder']}\" class=\"text_input align_center\" style=\"width: 80%;\" />", array("class" => "align_center"));

		}

		}

		else
{
$form_container->output_cell("&nbsp;", array("class" => "align_center"));
}

		else
{
$form_container->output_cell("&nbsp;", array("class" => "align_center"));
}

		



		$popup = new PopupMenu("usergroup_{$usergroup['gid']}", $lang->options);
$popup->add_item($lang->edit_group, "index.php?module=user-groups&amp;action=edit&amp;gid={$usergroup['gid']}");
$popup->add_item($lang->list_users, "index.php?module=user-users&amp;action=search&amp;results=1&amp;conditions[usergroup]={$usergroup['gid']}");

		$popup = new PopupMenu("usergroup_{$usergroup['gid']}", $lang->options);
$popup->add_item($lang->edit_group, "index.php?module=user-groups&amp;action=edit&amp;gid={$usergroup['gid']}");
$popup->add_item($lang->list_users, "index.php?module=user-users&amp;action=search&amp;results=1&amp;conditions[usergroup]={$usergroup['gid']}");

Zeile 1329Zeile 1358
			$popup->add_item($lang->delete_group, "index.php?module=user-groups&amp;action=delete&amp;gid={$usergroup['gid']}&amp;my_post_key={$mybb->post_code}", "return AdminCP.deleteConfirmation(this, '{$lang->confirm_group_deletion}')");
}
$form_container->output_cell($popup->fetch(), array("class" => "align_center"));

			$popup->add_item($lang->delete_group, "index.php?module=user-groups&amp;action=delete&amp;gid={$usergroup['gid']}&amp;my_post_key={$mybb->post_code}", "return AdminCP.deleteConfirmation(this, '{$lang->confirm_group_deletion}')");
}
$form_container->output_cell($popup->fetch(), array("class" => "align_center"));

		$form_container->construct_row();
}


		$form_container->construct_row();
}


	if($form_container->num_rows() == 0)
{
$form_container->output_cell($lang->no_groups, array('colspan' => 4));
$form_container->construct_row();
}

	if($form_container->num_rows() == 0)
{
$form_container->output_cell($lang->no_groups, array('colspan' => 4));
$form_container->construct_row();
}

	



	$form_container->end();

	$form_container->end();

	



	$buttons = array();
$buttons[] = $form->generate_submit_button($lang->update_groups_order);
$form->output_submit_wrapper($buttons);

	$buttons = array();
$buttons[] = $form->generate_submit_button($lang->update_groups_order);
$form->output_submit_wrapper($buttons);

	



	$form->end();

	$form->end();

	



	echo <<<LEGEND
<br />
<fieldset>

	echo <<<LEGEND
<br />
<fieldset>

Zeile 1354Zeile 1383
<img src="styles/default/images/icons/default.gif" alt="{$lang->default_user_group}" style="vertical-align: middle;" /> {$lang->default_user_group}
</fieldset>
LEGEND;

<img src="styles/default/images/icons/default.gif" alt="{$lang->default_user_group}" style="vertical-align: middle;" /> {$lang->default_user_group}
</fieldset>
LEGEND;

	



	$page->output_footer();
}
?>

	$page->output_footer();
}
?>