Vergleich usercp.php - 1.8.4 - 1.8.6

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 26Zeile 26
$templatelist .= ",usercp_editlists_no_buddies,usercp_editlists_no_ignored,usercp_editlists_no_requests,usercp_editlists_received_requests,usercp_editlists_sent_requests,usercp_drafts_draft_thread,usercp_drafts_draft_forum";
$templatelist .= ",usercp_usergroups_leader_usergroup_memberlist,usercp_usergroups_leader_usergroup_moderaterequests,usercp_usergroups_memberof_usergroup_leaveprimary,usercp_usergroups_memberof_usergroup_display,usercp_email";
$templatelist .= ",usercp_usergroups_memberof_usergroup_leaveleader,usercp_usergroups_memberof_usergroup_leaveother,usercp_usergroups_memberof_usergroup_leave,usercp_usergroups_joinable_usergroup_description,usercp_options_time_format";

$templatelist .= ",usercp_editlists_no_buddies,usercp_editlists_no_ignored,usercp_editlists_no_requests,usercp_editlists_received_requests,usercp_editlists_sent_requests,usercp_drafts_draft_thread,usercp_drafts_draft_forum";
$templatelist .= ",usercp_usergroups_leader_usergroup_memberlist,usercp_usergroups_leader_usergroup_moderaterequests,usercp_usergroups_memberof_usergroup_leaveprimary,usercp_usergroups_memberof_usergroup_display,usercp_email";
$templatelist .= ",usercp_usergroups_memberof_usergroup_leaveleader,usercp_usergroups_memberof_usergroup_leaveother,usercp_usergroups_memberof_usergroup_leave,usercp_usergroups_joinable_usergroup_description,usercp_options_time_format";

$templatelist .= ",usercp_editlists_sent_request,usercp_editlists_received_request,usercp_drafts_none,usercp_usergroups_memberof_usergroup_setdisplay,usercp_usergroups_memberof_usergroup_description,usercp_editlists_user,usercp_profile_day,usercp_profile_contact_fields,usercp_profile_contact_fields_field, usercp_profile_website";

$templatelist .= ",usercp_editlists_sent_request,usercp_editlists_received_request,usercp_drafts_none,usercp_usergroups_memberof_usergroup_setdisplay,usercp_usergroups_memberof_usergroup_description,usercp_editlists_user,usercp_profile_day,usercp_profile_contact_fields,usercp_profile_contact_fields_field,usercp_profile_website";


require_once "./global.php";
require_once MYBB_ROOT."inc/functions_post.php";


require_once "./global.php";
require_once MYBB_ROOT."inc/functions_post.php";

Zeile 411Zeile 411

$contact_fields = array();
$contactfields = '';


$contact_fields = array();
$contactfields = '';

 
	$cfieldsshow = false;


	foreach(array('icq', 'aim', 'yahoo', 'skype', 'google') as $cfield)
{
$contact_fields[$cfield] = '';

	foreach(array('icq', 'aim', 'yahoo', 'skype', 'google') as $cfield)
{
$contact_fields[$cfield] = '';

Zeile 434Zeile 436
		eval('$contact_fields[$cfield] = "'.$templates->get('usercp_profile_contact_fields_field').'";');
}


		eval('$contact_fields[$cfield] = "'.$templates->get('usercp_profile_contact_fields_field').'";');
}


	if(!empty($cfieldsshow))

	if($cfieldsshow)

	{
eval('$contactfields = "'.$templates->get('usercp_profile_contact_fields').'";');
}

	{
eval('$contactfields = "'.$templates->get('usercp_profile_contact_fields').'";');
}

Zeile 578Zeile 580
						$val = str_replace("\n", "\\n", $val);

$sel = "";

						$val = str_replace("\n", "\\n", $val);

$sel = "";

						if($val == $seloptions[$val])

						if(isset($seloptions[$val]) && $val == $seloptions[$val])

						{
$sel = " selected=\"selected\"";
}

						{
$sel = " selected=\"selected\"";
}

Zeile 658Zeile 660
					foreach($expoptions as $key => $val)
{
$checked = "";

					foreach($expoptions as $key => $val)
{
$checked = "";

						if($val == $seloptions[$val])

						if(isset($seloptions[$val]) && $val == $seloptions[$val])

						{
$checked = " checked=\"checked\"";
}

						{
$checked = " checked=\"checked\"";
}

Zeile 718Zeile 720
			{
if($title['posts'] <= $mybb->user['postnum'])
{

			{
if($title['posts'] <= $mybb->user['postnum'])
{

					$defaulttitle = $title['title'];

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

					break;
}
}

					break;
}
}

Zeile 790Zeile 792
		"dateformat" => $mybb->get_input('dateformat', MyBB::INPUT_INT),
"timeformat" => $mybb->get_input('timeformat', MyBB::INPUT_INT),
"timezone" => $db->escape_string($mybb->get_input('timezoneoffset')),

		"dateformat" => $mybb->get_input('dateformat', MyBB::INPUT_INT),
"timeformat" => $mybb->get_input('timeformat', MyBB::INPUT_INT),
"timezone" => $db->escape_string($mybb->get_input('timezoneoffset')),

		"language" => $mybb->get_input('language')



		"language" => $mybb->get_input('language'),
'usergroup' => $mybb->user['usergroup'],
'additionalgroups' => $mybb->user['additionalgroups']

	);

$user['options'] = array(

	);

$user['options'] = array(

Zeile 2052Zeile 2056
		else
{
$sigimgcode = $lang->off;

		else
{
$sigimgcode = $lang->off;

		}

		}

		$sig = htmlspecialchars_uni($sig);
$lang->edit_sig_note2 = $lang->sprintf($lang->edit_sig_note2, $sigsmilies, $sigmycode, $sigimgcode, $sightml, $mybb->settings['siglength']);


		$sig = htmlspecialchars_uni($sig);
$lang->edit_sig_note2 = $lang->sprintf($lang->edit_sig_note2, $sigsmilies, $sigmycode, $sigimgcode, $sightml, $mybb->settings['siglength']);


Zeile 2153Zeile 2157
			);

$db->update_query("users", $updated_avatar, "uid = '{$mybb->user['uid']}'");

			);

$db->update_query("users", $updated_avatar, "uid = '{$mybb->user['uid']}'");

		}
else
{

		}
else
{

			$mybb->input['avatarurl'] = preg_replace("#script:#i", "", $mybb->get_input('avatarurl'));
$ext = get_extension($mybb->input['avatarurl']);


			$mybb->input['avatarurl'] = preg_replace("#script:#i", "", $mybb->get_input('avatarurl'));
$ext = get_extension($mybb->input['avatarurl']);


Zeile 2257Zeile 2261
	{
$maxsize = get_friendly_size($mybb->settings['avatarsize']*1024);
$lang->avatar_note .= "<br />".$lang->sprintf($lang->avatar_note_size, $maxsize);

	{
$maxsize = get_friendly_size($mybb->settings['avatarsize']*1024);
$lang->avatar_note .= "<br />".$lang->sprintf($lang->avatar_note_size, $maxsize);

	}

	}


$auto_resize = '';
if($mybb->settings['avatarresizing'] == "auto")


$auto_resize = '';
if($mybb->settings['avatarresizing'] == "auto")

	{

	{

		eval("\$auto_resize = \"".$templates->get("usercp_avatar_auto_resize_auto")."\";");
}
else if($mybb->settings['avatarresizing'] == "user")

		eval("\$auto_resize = \"".$templates->get("usercp_avatar_auto_resize_auto")."\";");
}
else if($mybb->settings['avatarresizing'] == "user")

	{

	{

		eval("\$auto_resize = \"".$templates->get("usercp_avatar_auto_resize_user")."\";");
}


		eval("\$auto_resize = \"".$templates->get("usercp_avatar_auto_resize_user")."\";");
}


Zeile 2273Zeile 2277
	if($mybb->usergroup['canuploadavatars'] == 1)
{
eval("\$avatarupload = \"".$templates->get("usercp_avatar_upload")."\";");

	if($mybb->usergroup['canuploadavatars'] == 1)
{
eval("\$avatarupload = \"".$templates->get("usercp_avatar_upload")."\";");

	}


	}


	$removeavatar = '';
if(!empty($mybb->user['avatar']))
{
eval("\$removeavatar = \"".$templates->get("usercp_avatar_remove")."\";");

	$removeavatar = '';
if(!empty($mybb->user['avatar']))
{
eval("\$removeavatar = \"".$templates->get("usercp_avatar_remove")."\";");

	}

	}


$plugins->run_hooks("usercp_avatar_end");



$plugins->run_hooks("usercp_avatar_end");


Zeile 2293Zeile 2297
}

if($mybb->input['action'] == "acceptrequest")

}

if($mybb->input['action'] == "acceptrequest")

{
// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

// Validate request
$query = $db->simple_select('buddyrequests', '*', 'id='.$mybb->get_input('id', MyBB::INPUT_INT).' AND touid='.(int)$mybb->user['uid']);
$request = $db->fetch_array($query);
if(empty($request))
{
error($lang->invalid_request);
}

$plugins->run_hooks("usercp_acceptrequest_start");

$user = get_user($request['uid']);
if(!empty($user))

{
// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

// Validate request
$query = $db->simple_select('buddyrequests', '*', 'id='.$mybb->get_input('id', MyBB::INPUT_INT).' AND touid='.(int)$mybb->user['uid']);
$request = $db->fetch_array($query);
if(empty($request))
{
error($lang->invalid_request);
}

$plugins->run_hooks("usercp_acceptrequest_start");

$user = get_user($request['uid']);
if(!empty($user))

	{
// We want to add us to this user's buddy list
if($user['buddylist'] != '')

	{
// We want to add us to this user's buddy list
if($user['buddylist'] != '')

Zeile 2403Zeile 2407
	
// Validate request
$query = $db->simple_select('buddyrequests', '*', 'id='.$mybb->get_input('id', MyBB::INPUT_INT).' AND touid='.(int)$mybb->user['uid']);

	
// Validate request
$query = $db->simple_select('buddyrequests', '*', 'id='.$mybb->get_input('id', MyBB::INPUT_INT).' AND touid='.(int)$mybb->user['uid']);

	$request = $db->fetch_array($query);
if(empty($request))
{
error($lang->invalid_request);
}

$plugins->run_hooks("usercp_declinerequest_start");


	$request = $db->fetch_array($query);
if(empty($request))
{
error($lang->invalid_request);
}

$plugins->run_hooks("usercp_declinerequest_start");


	$user = get_user($request['uid']);
if(!empty($user))
{
$db->delete_query('buddyrequests', 'id='.(int)$request['id']);
}
else

	$user = get_user($request['uid']);
if(!empty($user))
{
$db->delete_query('buddyrequests', 'id='.(int)$request['id']);
}
else

	{

	{

		error($lang->user_doesnt_exist);
}


		error($lang->user_doesnt_exist);
}


Zeile 2461Zeile 2465
		if($mybb->user['ignorelist'])
{
$existing_users = explode(",", $mybb->user['ignorelist']);

		if($mybb->user['ignorelist'])
{
$existing_users = explode(",", $mybb->user['ignorelist']);

		}

		}


if($mybb->user['buddylist'])
{
// Create a list of buddies...
$selected_list = explode(",", $mybb->user['buddylist']);


if($mybb->user['buddylist'])
{
// Create a list of buddies...
$selected_list = explode(",", $mybb->user['buddylist']);

		}

		}

	}
else
{

	}
else
{

Zeile 2485Zeile 2489

$error_message = "";
$message = "";


$error_message = "";
$message = "";





	// Adding one or more users to this list
if($mybb->get_input('add_username'))
{

	// Adding one or more users to this list
if($mybb->get_input('add_username'))
{

Zeile 2510Zeile 2514
				continue;
}
$users[$key] = $db->escape_string($username);

				continue;
}
$users[$key] = $db->escape_string($username);

		}


		}


		// Get the requests we have sent that are still pending
$query = $db->simple_select('buddyrequests', 'touid', 'uid='.(int)$mybb->user['uid']);
$requests = array();

		// Get the requests we have sent that are still pending
$query = $db->simple_select('buddyrequests', 'touid', 'uid='.(int)$mybb->user['uid']);
$requests = array();

Zeile 2610Zeile 2614
					$pm = array(
'subject' => 'buddyrequest_new_buddy',
'message' => 'buddyrequest_new_buddy_message',

					$pm = array(
'subject' => 'buddyrequest_new_buddy',
'message' => 'buddyrequest_new_buddy_message',

						'touid' => $user['uid'],
'receivepms' => (int)$user['buddyrequestspm'],
'language' => $user['language'],
'language_file' => 'usercp'

						'touid' => $user['uid'],
'receivepms' => (int)$user['buddyrequestspm'],
'language' => $user['language'],
'language_file' => 'usercp'

					);

send_pm($pm);

					);

send_pm($pm);

Zeile 2662Zeile 2666
			else
{
$message = $lang->users_added_to_buddy_list;

			else
{
$message = $lang->users_added_to_buddy_list;

			}
}

			}
}


if($adding_self == true)
{
if($mybb->get_input('manage') == "ignored")
{
$error_message = $lang->cant_add_self_to_ignore_list;


if($adding_self == true)
{
if($mybb->get_input('manage') == "ignored")
{
$error_message = $lang->cant_add_self_to_ignore_list;

			}

			}

			else
{
$error_message = $lang->cant_add_self_to_buddy_list;

			else
{
$error_message = $lang->cant_add_self_to_buddy_list;

			}
}


			}
}


		if(count($existing_users) == 0)
{
$message = "";

		if(count($existing_users) == 0)
{
$message = "";

Zeile 2708Zeile 2712
				{
$user['buddylist'] = array();
}

				{
$user['buddylist'] = array();
}

				

				

				$key = array_search($mybb->get_input('delete', MyBB::INPUT_INT), $user['buddylist']);
unset($user['buddylist'][$key]);

// Now we have the new list, so throw it all back together
$new_list = implode(",", $user['buddylist']);

				$key = array_search($mybb->get_input('delete', MyBB::INPUT_INT), $user['buddylist']);
unset($user['buddylist'][$key]);

// Now we have the new list, so throw it all back together
$new_list = implode(",", $user['buddylist']);





				// And clean it up a little to ensure there is no possibility of bad values
$new_list = preg_replace("#,{2,}#", ",", $new_list);
$new_list = preg_replace("#[^0-9,]#", "", $new_list);

				// And clean it up a little to ensure there is no possibility of bad values
$new_list = preg_replace("#,{2,}#", ",", $new_list);
$new_list = preg_replace("#[^0-9,]#", "", $new_list);

Zeile 2816Zeile 2820
				{
echo "\$(\"#buddy_list\").html(\"<li>{$lang->buddy_list_empty}</li>\");\n";
}

				{
echo "\$(\"#buddy_list\").html(\"<li>{$lang->buddy_list_empty}</li>\");\n";
}

			}

			}

			else
{
echo "\$(\"#".$mybb->get_input('manage')."_count\").html(\"".count(explode(",", $new_list))."\");\n";
}
echo $message_js;
exit;

			else
{
echo "\$(\"#".$mybb->get_input('manage')."_count\").html(\"".count(explode(",", $new_list))."\");\n";
}
echo $message_js;
exit;

		}

		}

		$mybb->input['action'] = "editlists";
}
else
{
if($error_message)

		$mybb->input['action'] = "editlists";
}
else
{
if($error_message)

		{

		{

			$message .= "<br />".$error_message;
}
redirect("usercp.php?action=editlists#".$mybb->get_input('manage'), $message);
}
}

			$message .= "<br />".$error_message;
}
redirect("usercp.php?action=editlists#".$mybb->get_input('manage'), $message);
}
}





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

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





	$timecut = TIME_NOW - $mybb->settings['wolcutoff'];

	$timecut = TIME_NOW - $mybb->settings['wolcutoff'];





	// Fetch out buddies
$buddy_count = 0;
$buddy_list = '';

	// Fetch out buddies
$buddy_count = 0;
$buddy_list = '';

Zeile 2867Zeile 2871

$lang->current_buddies = $lang->sprintf($lang->current_buddies, $buddy_count);
if(!$buddy_list)


$lang->current_buddies = $lang->sprintf($lang->current_buddies, $buddy_count);
if(!$buddy_list)

	{
eval("\$buddy_list = \"".$templates->get("usercp_editlists_no_buddies")."\";");
}


	{
eval("\$buddy_list = \"".$templates->get("usercp_editlists_no_buddies")."\";");
}


	// Fetch out ignore list users
$ignore_count = 0;
$ignore_list = '';

	// Fetch out ignore list users
$ignore_count = 0;
$ignore_list = '';

Zeile 3125Zeile 3129
		}

$dispgroup = $usergroups[$mybb->get_input('displaygroup', MyBB::INPUT_INT)];

		}

$dispgroup = $usergroups[$mybb->get_input('displaygroup', MyBB::INPUT_INT)];

		if($dispgroup['candisplaygroup'] != 1)
{

		if($dispgroup['candisplaygroup'] != 1)
{

			error($lang->cannot_set_displaygroup);
}
$db->update_query("users", array('displaygroup' => $mybb->get_input('displaygroup', MyBB::INPUT_INT)), "uid='".$mybb->user['uid']."'");

			error($lang->cannot_set_displaygroup);
}
$db->update_query("users", array('displaygroup' => $mybb->get_input('displaygroup', MyBB::INPUT_INT)), "uid='".$mybb->user['uid']."'");

Zeile 3279Zeile 3283
		}
}
// Show listing of various group related things

		}
}
// Show listing of various group related things





	// List of groups this user is a leader of
$groupsledlist = '';


	// List of groups this user is a leader of
$groupsledlist = '';


Zeile 3310Zeile 3314
	}

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

	}

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

	{

	{

		$memberlistlink = $moderaterequestslink = '';
eval("\$memberlistlink = \"".$templates->get("usercp_usergroups_leader_usergroup_memberlist")."\";");
$usergroup['title'] = htmlspecialchars_uni($usergroup['title']);
if($usergroup['type'] != 4)
{
$usergroup['joinrequests'] = '--';

		$memberlistlink = $moderaterequestslink = '';
eval("\$memberlistlink = \"".$templates->get("usercp_usergroups_leader_usergroup_memberlist")."\";");
$usergroup['title'] = htmlspecialchars_uni($usergroup['title']);
if($usergroup['type'] != 4)
{
$usergroup['joinrequests'] = '--';

		}

		}

		if($usergroup['joinrequests'] > 0 && $usergroup['canmanagerequests'] == 1)
{
eval("\$moderaterequestslink = \"".$templates->get("usercp_usergroups_leader_usergroup_moderaterequests")."\";");

		if($usergroup['joinrequests'] > 0 && $usergroup['canmanagerequests'] == 1)
{
eval("\$moderaterequestslink = \"".$templates->get("usercp_usergroups_leader_usergroup_moderaterequests")."\";");

Zeile 3330Zeile 3334
	if($groupsledlist)
{
eval("\$leadinggroups = \"".$templates->get("usercp_usergroups_leader")."\";");

	if($groupsledlist)
{
eval("\$leadinggroups = \"".$templates->get("usercp_usergroups_leader")."\";");

	}


	}


	// Fetch the list of groups the member is in
// Do the primary group first
$usergroup = $usergroups[$mybb->user['usergroup']];

	// Fetch the list of groups the member is in
// Do the primary group first
$usergroup = $usergroups[$mybb->user['usergroup']];

Zeile 3363Zeile 3367
			$showmemberof = true;

if(isset($groupleader[$usergroup['gid']]))

			$showmemberof = true;

if(isset($groupleader[$usergroup['gid']]))

			{

			{

				eval("\$leavelink = \"".$templates->get("usercp_usergroups_memberof_usergroup_leaveleader")."\";");
}
elseif($usergroup['type'] != 4 && $usergroup['type'] != 3 && $usergroup['type'] != 5)

				eval("\$leavelink = \"".$templates->get("usercp_usergroups_memberof_usergroup_leaveleader")."\";");
}
elseif($usergroup['type'] != 4 && $usergroup['type'] != 3 && $usergroup['type'] != 5)

Zeile 3382Zeile 3386
			{
$usergroup['description'] = htmlspecialchars_uni($usergroup['description']);
eval("\$description = \"".$templates->get("usercp_usergroups_memberof_usergroup_description")."\";");

			{
$usergroup['description'] = htmlspecialchars_uni($usergroup['description']);
eval("\$description = \"".$templates->get("usercp_usergroups_memberof_usergroup_description")."\";");

			}

			}

			$trow = alt_trow();
if($usergroup['candisplaygroup'] == 1 && $usergroup['gid'] == $mybb->user['displaygroup'])
{
eval("\$displaycode = \"".$templates->get("usercp_usergroups_memberof_usergroup_display")."\";");
}
elseif($usergroup['candisplaygroup'] == 1)

			$trow = alt_trow();
if($usergroup['candisplaygroup'] == 1 && $usergroup['gid'] == $mybb->user['displaygroup'])
{
eval("\$displaycode = \"".$templates->get("usercp_usergroups_memberof_usergroup_display")."\";");
}
elseif($usergroup['candisplaygroup'] == 1)

			{

			{

				eval("\$displaycode = \"".$templates->get("usercp_usergroups_memberof_usergroup_setdisplay")."\";");
}
else

				eval("\$displaycode = \"".$templates->get("usercp_usergroups_memberof_usergroup_setdisplay")."\";");
}
else

Zeile 3414Zeile 3418
	{
$existinggroups .= ",".$mybb->user['additionalgroups'];
}

	{
$existinggroups .= ",".$mybb->user['additionalgroups'];
}





	$joinablegroups = $joinablegrouplist = '';
$query = $db->simple_select("usergroups", "*", "(type='3' OR type='4' OR type='5') AND gid NOT IN ($existinggroups)", array('order_by' => 'title'));
while($usergroup = $db->fetch_array($query))

	$joinablegroups = $joinablegrouplist = '';
$query = $db->simple_select("usergroups", "*", "(type='3' OR type='4' OR type='5') AND gid NOT IN ($existinggroups)", array('order_by' => 'title'));
while($usergroup = $db->fetch_array($query))

Zeile 3433Zeile 3437
		if($usergroup['type'] == 4)
{
$conditions = $lang->usergroup_joins_moderated;

		if($usergroup['type'] == 4)
{
$conditions = $lang->usergroup_joins_moderated;

		}

		}

		elseif($usergroup['type'] == 5)
{
$conditions = $lang->usergroup_joins_invite;

		elseif($usergroup['type'] == 5)
{
$conditions = $lang->usergroup_joins_invite;

Zeile 3453Zeile 3457
			$joinlink = $lang->sprintf($lang->pending_invitation, $usergroup['gid'], $mybb->post_code);
}
elseif($usergroup['type'] == 5)

			$joinlink = $lang->sprintf($lang->pending_invitation, $usergroup['gid'], $mybb->post_code);
}
elseif($usergroup['type'] == 5)

		{

		{

			$joinlink = "--";
}
else
{
eval("\$joinlink = \"".$templates->get("usercp_usergroups_joinable_usergroup_join")."\";");

			$joinlink = "--";
}
else
{
eval("\$joinlink = \"".$templates->get("usercp_usergroups_joinable_usergroup_join")."\";");

		}

		}


$usergroupleaders = '';
if(!empty($groupleaders[$usergroup['gid']]))


$usergroupleaders = '';
if(!empty($groupleaders[$usergroup['gid']]))

Zeile 3484Zeile 3488
	if($joinablegrouplist)
{
eval("\$joinablegroups = \"".$templates->get("usercp_usergroups_joinable")."\";");

	if($joinablegrouplist)
{
eval("\$joinablegroups = \"".$templates->get("usercp_usergroups_joinable")."\";");

	}

	}


$plugins->run_hooks("usercp_usergroups_end");



$plugins->run_hooks("usercp_usergroups_end");


Zeile 3586Zeile 3590

$multipage = multipage($totalattachments, $perpage, $page, "usercp.php?action=attachments");
$bandwidth = get_friendly_size($bandwidth);


$multipage = multipage($totalattachments, $perpage, $page, "usercp.php?action=attachments");
$bandwidth = get_friendly_size($bandwidth);





	if(!$attachments)
{
eval("\$attachments = \"".$templates->get("usercp_attachments_none")."\";");

	if(!$attachments)
{
eval("\$attachments = \"".$templates->get("usercp_attachments_none")."\";");

Zeile 3689Zeile 3693
	$latest_warnings = '';
if($mybb->settings['enablewarningsystem'] != 0 && $mybb->settings['canviewownwarning'] != 0)
{

	$latest_warnings = '';
if($mybb->settings['enablewarningsystem'] != 0 && $mybb->settings['canviewownwarning'] != 0)
{

 
		if($mybb->settings['maxwarningpoints'] < 1)
{
$mybb->settings['maxwarningpoints'] = 10;
}

		$warning_level = round($mybb->user['warningpoints']/$mybb->settings['maxwarningpoints']*100);
if($warning_level > 100)
{

		$warning_level = round($mybb->user['warningpoints']/$mybb->settings['maxwarningpoints']*100);
if($warning_level > 100)
{