Vergleich online.php - 1.6.8 - 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: online.php 5828 2012-05-08 16:06:16Z Tomm $

 * $Id$

 */

define("IN_MYBB", 1);
define('THIS_SCRIPT', 'online.php');


 */

define("IN_MYBB", 1);
define('THIS_SCRIPT', 'online.php');


$templatelist = "online,online_row,online_row_ip,online_today,online_today_row,online_iplookup,mostonline";

$templatelist = "online,online_row,online_row_ip,online_today,online_today_row";

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

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

Zeile 42Zeile 42
	$query = $db->simple_select("users", "COUNT(uid) AS users", "lastactive > '{$threshold}' AND invisible = '1'");
$invis_count = $db->fetch_field($query, "users");


	$query = $db->simple_select("users", "COUNT(uid) AS users", "lastactive > '{$threshold}' AND invisible = '1'");
$invis_count = $db->fetch_field($query, "users");


 
	if(!$mybb->settings['threadsperpage'] || (int)$mybb->settings['threadsperpage'] < 1)
{
$mybb->settings['threadsperpage'] = 20;
}


	// Add pagination
$perpage = $mybb->settings['threadsperpage'];

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

	// Add pagination
$perpage = $mybb->settings['threadsperpage'];

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

	{

	{

		$page = intval($mybb->input['page']);
$start = ($page-1) * $perpage;
$pages = ceil($todaycount / $perpage);

		$page = intval($mybb->input['page']);
$start = ($page-1) * $perpage;
$pages = ceil($todaycount / $perpage);

Zeile 54Zeile 59
		{
$start = 0;
$page = 1;

		{
$start = 0;
$page = 1;

		}
}
else
{

		}
}
else
{

		$start = 0;
$page = 1;
}

		$start = 0;
$page = 1;
}





	$query = $db->simple_select("users", "*", "lastactive > '{$threshold}'", array("order_by" => "lastactive", "order_dir" => "desc", "limit" => $perpage, "limit_start" => $start));

$todayrows = '';

	$query = $db->simple_select("users", "*", "lastactive > '{$threshold}'", array("order_by" => "lastactive", "order_dir" => "desc", "limit" => $perpage, "limit_start" => $start));

$todayrows = '';

Zeile 71Zeile 76
		if($online['invisible'] == 1)
{
$invisiblemark = "*";

		if($online['invisible'] == 1)
{
$invisiblemark = "*";

		}


		}


		if($online['invisible'] != 1 || $mybb->usergroup['canviewwolinvis'] == 1 || $online['uid'] == $mybb->user['uid'])
{
$username = $online['username'];

		if($online['invisible'] != 1 || $mybb->usergroup['canviewwolinvis'] == 1 || $online['uid'] == $mybb->user['uid'])
{
$username = $online['username'];

Zeile 87Zeile 92
	if($todaycount == 1)
{
$onlinetoday = $lang->member_online_today;

	if($todaycount == 1)
{
$onlinetoday = $lang->member_online_today;

	}
else

	}
else

	{
$onlinetoday = $lang->sprintf($lang->members_were_online_today, $todaycount);
}

	{
$onlinetoday = $lang->sprintf($lang->members_were_online_today, $todaycount);
}





	if($invis_count)
{
$string = $lang->members_online_hidden;

	if($invis_count)
{
$string = $lang->members_online_hidden;





		if($invis_count == 1)
{
$string = $lang->member_online_hidden;
}

$onlinetoday .= $lang->sprintf($string, $invis_count);

		if($invis_count == 1)
{
$string = $lang->member_online_hidden;
}

$onlinetoday .= $lang->sprintf($string, $invis_count);

	}

	}


$multipage = multipage($todaycount, $perpage, $page, "online.php?action=today");



$multipage = multipage($todaycount, $perpage, $page, "online.php?action=today");


Zeile 118Zeile 123

// Custom sorting options
if($mybb->input['sortby'] == "username")


// Custom sorting options
if($mybb->input['sortby'] == "username")

	{

	{

		$sql = "u.username ASC, s.time DESC";
$refresh_string = "?sortby=username";
}

		$sql = "u.username ASC, s.time DESC";
$refresh_string = "?sortby=username";
}

Zeile 165Zeile 170
			break;
}


			break;
}


 
	if(!$mybb->settings['threadsperpage'] || (int)$mybb->settings['threadsperpage'] < 1)
{
$mybb->settings['threadsperpage'] = 20;
}


	// How many pages are there?
$perpage = $mybb->settings['threadsperpage'];


	// How many pages are there?
$perpage = $mybb->settings['threadsperpage'];