mirror of
https://github.com/easy-wi/developer.git
synced 2025-02-20 11:23:28 +08:00
#272: Cronjob timestamps for resellers
This commit is contained in:
parent
0995f9d3cc
commit
15bff6b3db
@ -870,7 +870,7 @@ if (!isset($ip) or $_SERVER['SERVER_ADDR'] == $ip) {
|
||||
|
||||
}
|
||||
|
||||
$query = $sql->prepare("UPDATE `settings` SET `lastCronCloud`=UNIX_TIMESTAMP() WHERE `resellerid`=0 LIMIT 1");
|
||||
$query = $sql->prepare("UPDATE `settings` SET `lastCronCloud`=UNIX_TIMESTAMP()");
|
||||
$query->execute();
|
||||
|
||||
} else {
|
||||
|
@ -239,7 +239,7 @@ if (!isset($ip) or $ui->escaped('SERVER_ADDR', 'server') == $ip or in_array($ip,
|
||||
} else {
|
||||
$runJobs = false;
|
||||
}
|
||||
$query = $sql->prepare("UPDATE `settings` SET `lastCronJobs`=UNIX_TIMESTAMP() WHERE `resellerid`=0 LIMIT 1");
|
||||
$query = $sql->prepare("UPDATE `settings` SET `lastCronJobs`=UNIX_TIMESTAMP()");
|
||||
$query->execute();
|
||||
}
|
||||
}
|
||||
|
@ -550,7 +550,7 @@ if (!isset($ip) or $ui->escaped('SERVER_ADDR', 'server') == $ip or in_array($ip,
|
||||
$query->execute();
|
||||
}
|
||||
|
||||
$query = $sql->prepare("UPDATE `settings` SET `lastCronReboot`=UNIX_TIMESTAMP() WHERE `resellerid`=0 LIMIT 1");
|
||||
$query = $sql->prepare("UPDATE `settings` SET `lastCronReboot`=UNIX_TIMESTAMP()");
|
||||
$query->execute();
|
||||
|
||||
} else {
|
||||
|
@ -107,6 +107,6 @@ if (!isset($ip) or $ui->escaped('SERVER_ADDR', 'server') == $ip or in_array($ip,
|
||||
unset($rootServer);
|
||||
}
|
||||
|
||||
$query = $sql->prepare("UPDATE `settings` SET `lastCronUpdates`=UNIX_TIMESTAMP() WHERE `resellerid`=0 LIMIT 1");
|
||||
$query = $sql->prepare("UPDATE `settings` SET `lastCronUpdates`=UNIX_TIMESTAMP()");
|
||||
$query->execute();
|
||||
}
|
@ -738,7 +738,7 @@ if (!isset($ip) or $ui->escaped('SERVER_ADDR', 'server') == $ip or in_array($ip,
|
||||
$sd = $connection->ServerDetails($virtualserver_id);
|
||||
$newtrafficdata=round(($sd['connection_filetransfer_bytes_sent_total']+$sd['connection_filetransfer_bytes_received_total']) / 1024);
|
||||
|
||||
if ($resellersettings[$resellerid]['firstchecktime']<$resellersettings[$resellerid]['firstcheck']) {
|
||||
if (isset($resellersettings[$resellerid]['firstchecktime']) and isset($resellersettings[$resellerid]['firstcheck']) and $resellersettings[$resellerid]['firstchecktime'] < $resellersettings[$resellerid]['firstcheck']) {
|
||||
$filetraffic = 0;
|
||||
}
|
||||
|
||||
@ -971,7 +971,7 @@ if (!isset($ip) or $ui->escaped('SERVER_ADDR', 'server') == $ip or in_array($ip,
|
||||
}
|
||||
}
|
||||
flush();
|
||||
$query = $sql->prepare("UPDATE `settings` SET `lastCronStatus`=UNIX_TIMESTAMP() WHERE `resellerid`=0 LIMIT 1");
|
||||
$query = $sql->prepare("UPDATE `settings` SET `lastCronStatus`=UNIX_TIMESTAMP()");
|
||||
$query->execute();
|
||||
} else {
|
||||
header('Location: login.php');
|
||||
|
@ -272,10 +272,6 @@ if ($loguserip!='localhost') {
|
||||
|
||||
$page_detect_language = $elements[0];
|
||||
|
||||
if (substr($ui->escaped('REQUEST_URI', 'server'),-1) != '/' and !$ui->w('site',50, 'get')) {
|
||||
$throw404 = true;
|
||||
}
|
||||
|
||||
if (!preg_match('/^[a-z]{2}+$/', $elements[0]) and !$ui->w('site', 50, 'get')) {
|
||||
$throw404 = true;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user