
04-21-2012, 10:13 AM
|
|
|
Join Date: Oct 2006
Location: Toronto
Posts: 1,789
Благодарил(а): 0 раз(а)
Поблагодарили:
0 раз(а) в 0 сообщениях
|
|
Quote:
Originally Posted by ChrisTERiS
You need to edit memberlist.php. An example for Top posters last week (lines 219-240) is showing below:
Code:
// Week's Top Posters
// Put the usergroupids that you want to include
$include_groups = array(2,6,8);
if ($vbulletin->options["forummembers_week"] == '1') {
$timelimit = time() - 7 * 24 * 60 * 60;
$mostactiveweek_get = $db->query_read("
SELECT COUNT(post.dateline) AS postcount, post.userid,
user.userid, user.username, user.lastpostid, user.posts, user.usergroupid
FROM " . TABLE_PREFIX . "post AS post
JOIN " . TABLE_PREFIX . "user AS user ON (post.userid = user.userid)
WHERE user.posts != '0' AND user.usergroupid IN($include_groups) AND post.dateline>'".$timelimit."'
GROUP BY post.userid
ORDER BY postcount DESC
LIMIT $limit
");
$users = array();
while($user = $db->fetch_array($mostactiveweek_get))
{
$users[] = $user;
$totalposts = $db->query_first("SELECT COUNT(postid) AS postcount FROM ".TABLE_PREFIX."post WHERE dateline>'".$timelimit."'");
$mostactiveusersweek = printUsers($users, $vbulletin->options['forummembers_week_text'], 2, $totalposts['postcount']);
unset($users);
}
}
Hope that it helps.
Chris
|
It does Sir ..
Thank you ... very gracious of you to take the time to do this ...
Regards,
Doug
|