Vergleich global.php - 1.8.10 - 1.8.17

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 27Zeile 27
{
$cache->update_usergroups();
$groupscache = $cache->read('usergroups');

{
$cache->update_usergroups();
$groupscache = $cache->read('usergroups');

}

if(!defined('THIS_SCRIPT'))
{
define('THIS_SCRIPT', '');

 
}

$current_page = my_strtolower(basename(THIS_SCRIPT));

}

$current_page = my_strtolower(basename(THIS_SCRIPT));

Zeile 431Zeile 426

$theme['imgdir'] = $mybb->get_asset_url($theme['imgdir']);
$theme['imglangdir'] = $mybb->get_asset_url($theme['imglangdir']);


$theme['imgdir'] = $mybb->get_asset_url($theme['imgdir']);
$theme['imglangdir'] = $mybb->get_asset_url($theme['imglangdir']);

}


}


// Theme logo - is it a relative URL to the forum root? Append bburl
if(!preg_match("#^(\.\.?(/|$)|([a-z0-9]+)://)#i", $theme['logo']) && substr($theme['logo'], 0, 1) != '/')
{

// Theme logo - is it a relative URL to the forum root? Append bburl
if(!preg_match("#^(\.\.?(/|$)|([a-z0-9]+)://)#i", $theme['logo']) && substr($theme['logo'], 0, 1) != '/')
{

Zeile 453Zeile 448
$templatelist .= ",global_pending_joinrequests,global_awaiting_activation,nav,nav_sep,nav_bit,nav_sep_active,nav_bit_active,footer_languageselect,footer_themeselect,global_unreadreports,footer_contactus";
$templatelist .= ",global_boardclosed_warning,global_bannedwarning,error_inline,error_nopermission_loggedin,error_nopermission,global_pm_alert,header_menu_search,header_menu_portal,redirect,footer_languageselect_option";
$templatelist .= ",video_dailymotion_embed,video_facebook_embed,video_liveleak_embed,video_metacafe_embed,video_myspacetv_embed,video_veoh_embed,video_vimeo_embed,video_yahoo_embed,video_youtube_embed,debug_summary";

$templatelist .= ",global_pending_joinrequests,global_awaiting_activation,nav,nav_sep,nav_bit,nav_sep_active,nav_bit_active,footer_languageselect,footer_themeselect,global_unreadreports,footer_contactus";
$templatelist .= ",global_boardclosed_warning,global_bannedwarning,error_inline,error_nopermission_loggedin,error_nopermission,global_pm_alert,header_menu_search,header_menu_portal,redirect,footer_languageselect_option";
$templatelist .= ",video_dailymotion_embed,video_facebook_embed,video_liveleak_embed,video_metacafe_embed,video_myspacetv_embed,video_veoh_embed,video_vimeo_embed,video_yahoo_embed,video_youtube_embed,debug_summary";

$templatelist .= ",smilieinsert_row,smilieinsert_row_empty,smilieinsert,smilieinsert_getmore,smilieinsert_smilie,global_board_offline_modal,footer_themeselector,task_image,usercp_themeselector_option";

$templatelist .= ",smilieinsert_row,smilieinsert_row_empty,smilieinsert,smilieinsert_getmore,smilieinsert_smilie,global_board_offline_modal,footer_themeselector,task_image,usercp_themeselector_option,php_warnings";

$templatelist .= ",mycode_code,mycode_email,mycode_img,mycode_php,mycode_quote_post,mycode_size_int,mycode_url,global_no_permission_modal,global_boardclosed_reason,nav_dropdown,global_remote_avatar_notice";

$templatelist .= ",mycode_code,mycode_email,mycode_img,mycode_php,mycode_quote_post,mycode_size_int,mycode_url,global_no_permission_modal,global_boardclosed_reason,nav_dropdown,global_remote_avatar_notice";

$templatelist .= ",header_welcomeblock_member_pms,header_welcomeblock_member_search,header_welcomeblock_guest,header_menu_calendar,header_menu_memberlist,global_dst_detection,header_quicksearch,smilie";


$templatelist .= ",header_welcomeblock_member_pms,header_welcomeblock_member_search,header_welcomeblock_guest,header_welcomeblock_guest_login_modal,header_welcomeblock_guest_login_modal_lockout";
$templatelist .= ",header_menu_calendar,header_menu_memberlist,global_dst_detection,header_quicksearch,smilie";

$templates->cache($db->escape_string($templatelist));

// Set the current date and time now

$templates->cache($db->escape_string($templatelist));

// Set the current date and time now

Zeile 485Zeile 481

// Prepare the main templates for use
$admincplink = $modcplink = $usercplink = '';


// Prepare the main templates for use
$admincplink = $modcplink = $usercplink = '';





// Load appropriate welcome block for the current logged in user
if($mybb->user['uid'] != 0)
{

// Load appropriate welcome block for the current logged in user
if($mybb->user['uid'] != 0)
{

Zeile 518Zeile 514
	// Tell the user their PM usage
$pmslink = '';
if($mybb->settings['enablepms'] != 0 && $mybb->usergroup['canusepms'] == 1)

	// Tell the user their PM usage
$pmslink = '';
if($mybb->settings['enablepms'] != 0 && $mybb->usergroup['canusepms'] == 1)

	{

	{

		$lang->welcome_pms_usage = $lang->sprintf($lang->welcome_pms_usage, my_number_format($mybb->user['pms_unread']), my_number_format($mybb->user['pms_total']));

eval('$pmslink = "'.$templates->get('header_welcomeblock_member_pms').'";');

		$lang->welcome_pms_usage = $lang->sprintf($lang->welcome_pms_usage, my_number_format($mybb->user['pms_unread']), my_number_format($mybb->user['pms_total']));

eval('$pmslink = "'.$templates->get('header_welcomeblock_member_pms').'";');

Zeile 544Zeile 540
			$login_username = $lang->login_username;
break;
}

			$login_username = $lang->login_username;
break;
}

 

if($mybb->cookies['lockoutexpiry'])
{
$secsleft = (int)($mybb->cookies['lockoutexpiry'] - TIME_NOW);
$hoursleft = floor($secsleft / 3600);
$minsleft = floor(($secsleft / 60) % 60);
$secsleft = floor($secsleft % 60);

$lang->failed_login_wait = $lang->sprintf($lang->failed_login_wait, $hoursleft, $minsleft, $secsleft);

eval('$loginform = "'.$templates->get('header_welcomeblock_guest_login_modal_lockout').'";');
}
else
{
eval('$loginform = "'.$templates->get('header_welcomeblock_guest_login_modal').'";');
}


	eval('$welcomeblock = "'.$templates->get('header_welcomeblock_guest').'";');
}


	eval('$welcomeblock = "'.$templates->get('header_welcomeblock_guest').'";');
}


Zeile 568Zeile 581
if($mybb->settings['portal'] == 1)
{
eval('$menu_portal = "'.$templates->get('header_menu_portal').'";');

if($mybb->settings['portal'] == 1)
{
eval('$menu_portal = "'.$templates->get('header_menu_portal').'";');

}

}


// See if there are any pending join requests for group leaders
$pending_joinrequests = '';


// See if there are any pending join requests for group leaders
$pending_joinrequests = '';

Zeile 576Zeile 589
if($mybb->user['uid'] != 0 && is_array($groupleaders) && array_key_exists($mybb->user['uid'], $groupleaders))
{
$groupleader = $groupleaders[$mybb->user['uid']];

if($mybb->user['uid'] != 0 && is_array($groupleaders) && array_key_exists($mybb->user['uid'], $groupleaders))
{
$groupleader = $groupleaders[$mybb->user['uid']];

 
	$showjoinnotice = false;


$gids = "'0'";
foreach($groupleader as $user)


$gids = "'0'";
foreach($groupleader as $user)

	{

	{

		if($user['canmanagerequests'] != 1)
{
continue;
}

$user['gid'] = (int)$user['gid'];

		if($user['canmanagerequests'] != 1)
{
continue;
}

$user['gid'] = (int)$user['gid'];

		$gids .= ",'{$user['gid']}'";
}

 




	$query = $db->simple_select('joinrequests', 'COUNT(uid) as total', "gid IN ({$gids}) AND invite='0'");
$total_joinrequests = $db->fetch_field($query, 'total');





		if(!empty($groupscache[$user['gid']]['joinable']) && $groupscache[$user['gid']]['joinable'] == 1)
{
$showjoinnotice = true;
$gids .= ",'{$user['gid']}'";
}
}





	if($total_joinrequests > 0)

	if($showjoinnotice)

	{

	{

		if($total_joinrequests == 1)




		$query = $db->simple_select('joinrequests', 'COUNT(uid) as total', "gid IN ({$gids}) AND invite='0'");
$total_joinrequests = $db->fetch_field($query, 'total');

if($total_joinrequests > 0)

		{

		{

			$lang->pending_joinrequests = $lang->pending_joinrequest;
}
else
{
$total_joinrequests = my_number_format($total_joinrequests);
$lang->pending_joinrequests = $lang->sprintf($lang->pending_joinrequests, $total_joinrequests);
}



			if($total_joinrequests == 1)
{
$lang->pending_joinrequests = $lang->pending_joinrequest;
}
else
{
$total_joinrequests = my_number_format($total_joinrequests);
$lang->pending_joinrequests = $lang->sprintf($lang->pending_joinrequests, $total_joinrequests);
}





		eval('$pending_joinrequests = "'.$templates->get('global_pending_joinrequests').'";');


			eval('$pending_joinrequests = "'.$templates->get('global_pending_joinrequests').'";');
}

	}
}


	}
}


Zeile 715Zeile 737

if($ban['lifted'] > 0)
{


if($ban['lifted'] > 0)
{

			$banlift = my_date($mybb->settings['dateformat'], $ban['lifted']) . $lang->comma . my_date($mybb->settings['timeformat'], $ban['lifted']);

			$banlift = my_date('normal', $ban['lifted']);

		}
}


		}
}


Zeile 966Zeile 988
		'logout',
),
'captcha.php',

		'logout',
),
'captcha.php',

 
	'contact.php',

);

// If the board is closed, the user is not an administrator and they're not trying to login, show the board closed message

);

// If the board is closed, the user is not an administrator and they're not trying to login, show the board closed message

Zeile 978Zeile 1001
	}

eval('$reason = "'.$templates->get('global_boardclosed_reason').'";');

	}

eval('$reason = "'.$templates->get('global_boardclosed_reason').'";');

	$lang->error_boardclosed .= $reason;

if(!$mybb->get_input('modal'))

	$lang->error_boardclosed .= $reason;

if(!$mybb->get_input('modal'))

	{
error($lang->error_boardclosed);
}

	{
error($lang->error_boardclosed);
}

Zeile 1008Zeile 1031
		'resetpassword',
),
'captcha.php',

		'resetpassword',
),
'captcha.php',

 
	'contact.php',

);

// If the board forces user to login/register, and the user is a guest, show the force login message

);

// If the board forces user to login/register, and the user is a guest, show the force login message

Zeile 1064Zeile 1088
			unset($allowable_actions);
}
else if(ALLOWABLE_PAGE !== 1)

			unset($allowable_actions);
}
else if(ALLOWABLE_PAGE !== 1)

		{

		{

			$notallowed = true;
}
}

			$notallowed = true;
}
}

Zeile 1109Zeile 1133
	$colcookie = $mybb->cookies['collapsed'];
}


	$colcookie = $mybb->cookies['collapsed'];
}


// set up collapsable items (to automatically show them us expanded)
$collapsed = array('boardstats' => '', 'boardstats_e' => '', 'quickreply' => '', 'quickreply_e' => '');
$collapsedimg = $collapsed;

$collapse = $collapsed = $collapsedimg = array();




if($colcookie)
{


if($colcookie)
{

	$col = explode("|", $colcookie);
if(!is_array($col))
{
$col[0] = $colcookie; // only one item
}
unset($collapsed);
foreach($col as $key => $val)

	// Preserve and don't unset $collapse, will be needed globally throughout many pages
$collapse = explode("|", $colcookie);
foreach($collapse as $val)





	{
$ex = $val."_e";
$co = $val."_c";

	{
$ex = $val."_e";
$co = $val."_c";