The original code is :
Code:
while ($forum = $vbulletin->db->fetch_array($forums))
{
$threads = $vbulletin->db->query_read("SELECT threadid, forumid, visible, open, pollid, title FROM " . TABLE_PREFIX . "thread WHERE forumid=$forum[forumid] AND visible IN (0,1,2) AND sticky IN (0,1) AND lastpost <= " . (TIMENOW - ($forum['pruneafter'] * 86400)));
while ($thread = $vbulletin->db->fetch_array($threads))
{
delete_thread($thread['threadid'], false, true, NULL, false, $thread);
}
build_forum_counters($forum['forumid']);
}
I would like to manually specify the forums and the number of days. Would this be correct?
Code:
while ($forum = $vbulletin->db->[7,8,9])
{
$threads = $vbulletin->db->query_read("SELECT threadid, forumid, visible, open, pollid, title FROM " . TABLE_PREFIX . "thread WHERE forumid=$forum[forumid] AND visible IN (0,1,2) AND sticky IN (0,1) AND lastpost <= " . (TIMENOW - (90* 86400)));
while ($thread = $vbulletin->db->fetch_array($threads))
{
delete_thread($thread['threadid'], false, true, NULL, false, $thread);
}
build_forum_counters($forum['forumid']);
}