Hello I have got problem with cron jobs in auto rank updating.
CRON doesn't work (even original one ) in TSSE 5.6 v1.2
PHP Code:
if (0 < intval ($promote_gig_limit))
{
$limit = $promote_gig_limit * 1024 * 1024 * 1024 * 50;
$query = mysql_query ('SELECT id FROM users WHERE usergroup =1 AND enabled = \'yes\' AND uploaded >= ' . $limit_user . ' AND (uploaded / downloaded) >= \'1.5\'');
++$CQueryCount;
if (0 < mysql_num_rows ($query))
{
$userids = array ();
while ($arr = mysql_fetch_assoc ($query))
{
$userids[] = $arr['id'];
}
if (count ($userids))
{
mysql_query ('UPDATE users SET usergroup =2 , modcomment = CONCAT(\'' . gmdate ('Y-m-d') . ' - Promoted to POWER USER by -AutoSystem.
\', modcomment) WHERE id IN (0,' . implode (',', $userids) . ')');
++$CQueryCount;
savelog ('Following user(s) has been promoted to Power User Class: ' . implode (', ', $userids) . '. Reason: Automatic Promotion System!');
++$CQueryCount;
foreach ($userids as $pid)
{
send_pm ($pid, $lang->cronjobs['promote_message'], $lang->cronjobs['promote_subject']);
++$CQueryCount;
}
}
unset ($limit);
unset ($maxdt);
unset ($userids);
unset ($pid);
}
}
No Errors when running CRON directly with
PHP Code:
error_reporting(E_ALL);
Could anyone help me out with that issue?