fixed timezone

This commit is contained in:
2026-09-24 11:08:03 +02:00
parent 1035f57b92
commit 35adb2808f
+7
View File
@@ -20,6 +20,13 @@ if (PHP_SAPI !== 'cli') {
date_default_timezone_set('Europe/Rome');
// --only-at=17 : esce senza fare nulla se in Italia non sono le 17 (server in UTC)
foreach ($argv as $a) {
if (preg_match('/^--only-at=(\d{1,2})$/', $a, $m) && (int) date('G') !== (int) $m[1]) {
exit(0);
}
}
$root = dirname(__DIR__);
chdir($root);
require_once $root . '/public/class/db-functions.php'; // include anche vendor/autoload.php