Vergleich memberlist.php - 1.8.16 - 1.8.23

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 40Zeile 40
	add_breadcrumb($lang->nav_memberlist_search);

$contact_fields = array();

	add_breadcrumb($lang->nav_memberlist_search);

$contact_fields = array();

	foreach(array('skype', 'google', 'yahoo', 'icq') as $field)

	foreach(array('skype', 'google', 'icq') as $field)

	{
$contact_fields[$field] = '';
$settingkey = 'allow'.$field.'field';

	{
$contact_fields[$field] = '';
$settingkey = 'allow'.$field.'field';

Zeile 151Zeile 151
		$mybb->input['order'] = "descending";
}
$order_check[$mybb->input['order']] = " checked=\"checked\"";

		$mybb->input['order'] = "descending";
}
$order_check[$mybb->input['order']] = " checked=\"checked\"";

 

if($sort_field == 'u.lastactive' && $mybb->usergroup['canviewwolinvis'] == 0)
{
$sort_field = "u.invisible ASC, CASE WHEN u.invisible = 1 THEN u.regdate ELSE u.lastactive END";
}


// Incoming results per page?
$mybb->input['perpage'] = $mybb->get_input('perpage', MyBB::INPUT_INT);


// Incoming results per page?
$mybb->input['perpage'] = $mybb->get_input('perpage', MyBB::INPUT_INT);

Zeile 161Zeile 166
	else if($mybb->settings['membersperpage'])
{
$per_page = $mybb->input['perpage'] = (int)$mybb->settings['membersperpage'];

	else if($mybb->settings['membersperpage'])
{
$per_page = $mybb->input['perpage'] = (int)$mybb->settings['membersperpage'];

	}

	}

	else
{
$per_page = $mybb->input['perpage'] = 20;

	else
{
$per_page = $mybb->input['perpage'] = 20;

	}


	}


	$search_query = '1=1';
$search_url = "";

switch($db->type)

	$search_query = '1=1';
$search_url = "";

switch($db->type)

	{

	{

		// PostgreSQL's LIKE is case sensitive
case "pgsql":
$like = "ILIKE";

		// PostgreSQL's LIKE is case sensitive
case "pgsql":
$like = "ILIKE";

Zeile 191Zeile 196
		else if(strlen($letter) == 1)
{
$search_query .= " AND u.username {$like} '".$db->escape_string_like($letter)."%'";

		else if(strlen($letter) == 1)
{
$search_query .= " AND u.username {$like} '".$db->escape_string_like($letter)."%'";

		}

		}

		$search_url .= "&letter={$letter}";
}


		$search_url .= "&letter={$letter}";
}


Zeile 206Zeile 211
		{
$search_query .= " AND u.username {$like} '".$username_like_query."%'";
$search_url .= "&username_match=begins";

		{
$search_query .= " AND u.username {$like} '".$username_like_query."%'";
$search_url .= "&username_match=begins";

		}

		}

		// Just contains

		// Just contains

 
		else if($mybb->input['username_match'] == "contains")
{
$search_query .= " AND u.username {$like} '%".$username_like_query."%'";
$search_url .= "&username_match=contains";
}
// Exact

		else
{

		else
{

			$search_query .= " AND u.username {$like} '%".$username_like_query."%'";

			$search_query .= " AND u.username='{$username_like_query}'";

		}

$search_url .= "&username=".urlencode($search_username);

		}

$search_url .= "&username=".urlencode($search_username);

Zeile 226Zeile 237
	}

// Search by contact field input

	}

// Search by contact field input

	foreach(array('icq', 'google', 'skype', 'yahoo') as $cfield)

	foreach(array('icq', 'google', 'skype') as $cfield)

	{
$csetting = 'allow'.$cfield.'field';
$mybb->input[$cfield] = trim($mybb->get_input($cfield));
if($mybb->input[$cfield] && $mybb->settings[$csetting] != '')

	{
$csetting = 'allow'.$cfield.'field';
$mybb->input[$cfield] = trim($mybb->get_input($cfield));
if($mybb->input[$cfield] && $mybb->settings[$csetting] != '')

		{

		{

			if($mybb->settings[$csetting] != -1)
{
$gids = explode(',', (string)$mybb->settings[$csetting]);

			if($mybb->settings[$csetting] != -1)
{
$gids = explode(',', (string)$mybb->settings[$csetting]);

Zeile 312Zeile 323
	if($page && $page > 0)
{
$start = ($page - 1) * $per_page;

	if($page && $page > 0)
{
$start = ($page - 1) * $per_page;

 
		$pages = ceil($num_users / $per_page);
if($page > $pages)
{
$start = 0;
$page = 1;
}

	}
else
{

	}
else
{

Zeile 368Zeile 385
		}

$displaygroupfields = array("title", "description", "namestyle", "usertitle", "stars", "starimage", "image");

		}

$displaygroupfields = array("title", "description", "namestyle", "usertitle", "stars", "starimage", "image");

 

if(!$user['displaygroup'])
{
$user['displaygroup'] = $user['usergroup'];
}


		$display_group = usergroup_displaygroup($user['displaygroup']);
if(is_array($display_group))

		$display_group = usergroup_displaygroup($user['displaygroup']);
if(is_array($display_group))

		{

		{

			$usergroup = array_merge($usergroup, $display_group);

			$usergroup = array_merge($usergroup, $display_group);

		}


		}


		// Build referral?
if($mybb->settings['usereferrals'] == 1)
{

		// Build referral?
if($mybb->settings['usereferrals'] == 1)
{

 
			$referral_count = (int) $user['referrals'];
if($referral_count > 0)
{
$uid = (int) $user['uid'];
eval("\$user['referrals'] = \"".$templates->get('member_referrals_link')."\";");
}


			eval("\$referral_bit = \"".$templates->get("memberlist_referrals_bit")."\";");
eval("\$referrals_option = \"".$templates->get("memberlist_referrals_option")."\";");
}

			eval("\$referral_bit = \"".$templates->get("memberlist_referrals_bit")."\";");
eval("\$referrals_option = \"".$templates->get("memberlist_referrals_option")."\";");
}

Zeile 388Zeile 418
			if(!empty($mybb->user['language']))
{
$language = $mybb->user['language'];

			if(!empty($mybb->user['language']))
{
$language = $mybb->user['language'];

			}

			}

			else
{
$language = $mybb->settings['bblanguage'];

			else
{
$language = $mybb->settings['bblanguage'];

Zeile 458Zeile 488
		$useravatar = format_avatar($user['avatar'], $user['avatardimensions'], my_strtolower($mybb->settings['memberlistmaxavatarsize']));
eval("\$user['avatar'] = \"".$templates->get("memberlist_user_avatar")."\";");


		$useravatar = format_avatar($user['avatar'], $user['avatardimensions'], my_strtolower($mybb->settings['memberlistmaxavatarsize']));
eval("\$user['avatar'] = \"".$templates->get("memberlist_user_avatar")."\";");


		if($user['invisible'] == 1 && $mybb->usergroup['canviewwolinvis'] != 1 && $user['uid'] != $mybb->user['uid'])


		$last_seen = max(array($user['lastactive'], $user['lastvisit']));
if(empty($last_seen))

		{
$user['lastvisit'] = $lang->lastvisit_never;

		{
$user['lastvisit'] = $lang->lastvisit_never;


if($user['lastvisit'])
{
// We have had at least some active time, hide it instead
$user['lastvisit'] = $lang->lastvisit_hidden;
}

 
		}
else
{

		}
else
{

			$user['lastvisit'] = my_date('relative', $user['lastactive']);









			// We have some stamp here
if($user['invisible'] == 1 && $mybb->usergroup['canviewwolinvis'] != 1 && $user['uid'] != $mybb->user['uid'])
{
$user['lastvisit'] = $lang->lastvisit_hidden;
}
else
{
$user['lastvisit'] = my_date('relative', $last_seen);
}

		}

$user['regdate'] = my_date('relative', $user['regdate']);

		}

$user['regdate'] = my_date('relative', $user['regdate']);