Лишний блок на главной, а главное - кому та инфа была нужна? Кто ею пользовался? Если нужна - ставьте...

includes/top_five.php
}
?>
// top five thanked users
if (($user_thanked = $cache->get('_top_five_thanked')) === false)
{
$user_thanked = array();
$sql = 'SELECT COUNT(t.post_id) AS tally, u.user_id, u.username, u.user_colour
FROM ' . THANKS_TABLE . ' t
LEFT JOIN ' . USERS_TABLE . ' u ON t.poster_id = u.user_id
GROUP BY t.poster_id
ORDER BY tally DESC';
$result = $db->sql_query_limit($sql, 5);
while ($row = $db->sql_fetchrow($result))
{
$user_thanked[$row['user_id']] = array(
'user_id' => $row['user_id'],
'username' => $row['username'],
'user_colour' => $row['user_colour'],
'user_thanks' => $row['tally'],
);
}
$db->sql_freeresult($result);
// cache this data for 5 minutes, this improves performance
$cache->put('_top_five_thanked', $user_thanked, 300);
}
foreach ($user_thanked as $row)
{
$username_string = get_username_string('full', $row['user_id'], $row['username'], $row['user_colour']);
$template->assign_block_vars('top_five_thanked',array(
'THANKS' => $row['user_thanks'] > 1 ? sprintf($user->lang['THANKEDS'], $row['user_thanks']) : sprintf($user->lang['THANKED'], $row['user_thanks']),
'USERNAME_FULL' => $username_string)
);
}
language/en/mods/top_five.php
'BY' => 'by:',
'TOP_THANKED' => 'Top Thanked Users',
'THANKED' => 'Thanked %d time',
'THANKEDS' => 'Thanked %d times',
styles/prosilver/template/top_five_body.html
<th style="width: 50%;">{L_NEWEST_TOPICS}</th>
<th style="width: 30%;">{L_NEWEST_TOPICS}</th>
<th style="width: 30%;">{L_TOP_FIVE_NEWEST}</th>
<th style="width: 20%;">{L_TOP_THANKED}</th>
<td valign="top"><!-- BEGIN top_five_newest -->{top_five_newest.USERNAME_FULL}<br /> {L_JOINED}: {top_five_newest.REG_DATE}<br /><!-- END top_five_newest --></td>
<td valign="top"><!-- BEGIN top_five_thanked -->{top_five_thanked.USERNAME_FULL}<br /> {top_five_thanked.THANKS}<br /><!-- END top_five_thanked --></td>
$cache->put('_top_five_thanked', $user_thanked, 300);
Вернуться в 450 модов движка форумов phpBB (до версии 3.0.14)