News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Most Time Online

Started by colby2152, October 11, 2011, 12:50:38 PM

Previous topic - Next topic

colby2152

Is there a way to see the most time online for X members over the past Y days?
ProFSL.com - Pro Fantasy Sports Leagues - Advanced fantasy sports leagues, contests, free chances at cash/prizes, and sports discussion.

Need a server? I am happy to advocate this hosting solution - hands on customer service and reliability is relieving!!!

TheListener

There are two mods.

Users logged in today and there is a 24 hour version too.

colby2152

Quote from: Brack1 on October 11, 2011, 12:53:34 PM
There are two mods.

Users logged in today and there is a 24 hour version too.

That is not what I wanted.  There is a 'Most Time Online' in the stats, but it shows only 10 users for all time.  I would want to see a longer member list and see most time online in past X days.
ProFSL.com - Pro Fantasy Sports Leagues - Advanced fantasy sports leagues, contests, free chances at cash/prizes, and sports discussion.

Need a server? I am happy to advocate this hosting solution - hands on customer service and reliability is relieving!!!

colby2152

ProFSL.com - Pro Fantasy Sports Leagues - Advanced fantasy sports leagues, contests, free chances at cash/prizes, and sports discussion.

Need a server? I am happy to advocate this hosting solution - hands on customer service and reliability is relieving!!!

colby2152

No responses on this at all?  Even a custom DB query would suffice.
ProFSL.com - Pro Fantasy Sports Leagues - Advanced fantasy sports leagues, contests, free chances at cash/prizes, and sports discussion.

Need a server? I am happy to advocate this hosting solution - hands on customer service and reliability is relieving!!!

colby2152

Quote from: colby2152 on November 02, 2011, 10:20:52 AM
No responses on this at all?  Even a custom DB query would suffice.

???
ProFSL.com - Pro Fantasy Sports Leagues - Advanced fantasy sports leagues, contests, free chances at cash/prizes, and sports discussion.

Need a server? I am happy to advocate this hosting solution - hands on customer service and reliability is relieving!!!

colby2152

I am still looking for a query.
ProFSL.com - Pro Fantasy Sports Leagues - Advanced fantasy sports leagues, contests, free chances at cash/prizes, and sports discussion.

Need a server? I am happy to advocate this hosting solution - hands on customer service and reliability is relieving!!!

colby2152

ProFSL.com - Pro Fantasy Sports Leagues - Advanced fantasy sports leagues, contests, free chances at cash/prizes, and sports discussion.

Need a server? I am happy to advocate this hosting solution - hands on customer service and reliability is relieving!!!

kattara

Quote from: colby2152 on December 15, 2011, 02:38:10 PM
Anybody?

Patience, young jedi...  I'm sure somebody knows something.  ;)

hcfwesker

Well, not a feature, but you can manipulate this by some editing, and just revert it back to normal.

Sources/Stats.php

Find
// Time online top 10.
$temp = cache_get_data('stats_total_time_members', 600);
$members_result = $smcFunc['db_query']('', '
SELECT id_member, real_name, total_time_logged_in
FROM {db_prefix}members' . (!empty($temp) ? '
WHERE id_member IN ({array_int:member_list_cached})' : '') . '
ORDER BY total_time_logged_in DESC
LIMIT 20',
array(
'member_list_cached' => $temp,
)
);
$context['top_time_online'] = array();
$temp2 = array();
$max_time_online = 1;
while ($row_members = $smcFunc['db_fetch_assoc']($members_result))
{
$temp2[] = (int) $row_members['id_member'];
if (count($context['top_time_online']) >= 10)
continue;


Mess around with the number settings.


colby2152

Thanks hcf... that's what I needed.
ProFSL.com - Pro Fantasy Sports Leagues - Advanced fantasy sports leagues, contests, free chances at cash/prizes, and sports discussion.

Need a server? I am happy to advocate this hosting solution - hands on customer service and reliability is relieving!!!

colby2152

One more thing... I would like to show a list of top X users per Time Online per Day in which they are eligible for this list if their Total Time Online is greater than Y hours.  This a bit more complicated since it is showing an average figure that must be calculated and be dependent upon a condition on another figure.
ProFSL.com - Pro Fantasy Sports Leagues - Advanced fantasy sports leagues, contests, free chances at cash/prizes, and sports discussion.

Need a server? I am happy to advocate this hosting solution - hands on customer service and reliability is relieving!!!

colby2152

Quote from: colby2152 on December 16, 2011, 09:00:50 AM
One more thing... I would like to show a list of top X users per Time Online per Day in which they are eligible for this list if their Total Time Online is greater than Y hours.  This a bit more complicated since it is showing an average figure that must be calculated and be dependent upon a condition on another figure.

Any thoughts?
ProFSL.com - Pro Fantasy Sports Leagues - Advanced fantasy sports leagues, contests, free chances at cash/prizes, and sports discussion.

Need a server? I am happy to advocate this hosting solution - hands on customer service and reliability is relieving!!!

hcfwesker

Seeing at it's going to involve some heavy customization, if it's even possible.  You'd probably be better off asking in the SMF Coding Discussion.

Advertisement: