I have installed this mod, and really like it.
One thing I would like to change is this:
In the Top threads and posts section, rather than show the All Time leaders, I'd love to show the most popular threads and posts from the last 24 hours.
I would imagine this would require a WHERE clause added here:
Code:
// top threads by views
$getthreads = $db->query_read("
SELECT threadid, title, views
FROM " . TABLE_PREFIX . "thread
WHERE visible = 1
AND forumid NOT IN (0$limitfids)
ORDER BY views DESC
LIMIT " . $vbulletin->options['psistats_toptflimit'] . "
");
and here:
Code:
// top threads by replies
$getthreads = $db->query_read("
SELECT threadid, title, replycount
FROM " . TABLE_PREFIX . "thread
WHERE visible = 1
AND replycount > 0
AND forumid NOT IN (0$limitfids)
ORDER BY replycount DESC
LIMIT " . $vbulletin->options['psistats_toptflimit'] . "
");
but I am not familar enough with SQL to do this.
Im guessing it's something close to this:
Code:
WHERE lastpost >= (curdate() - 24*60)
but that produces an error.
Any suggestions?
Thanks!