49 $info =
'@DEPRECATED_TEMP 20251010: this class will be removed in L* > 7.5.0, use external cronjobs instead")';
54 $this->oTwig = lib_twig_box::getInstance();
56 $this->cj_time = time();
58 $cronjob_ini = LEPTON_PATH.
"/config/cronjob.ini.php";
59 $this->cj_array = parse_ini_file($cronjob_ini,
true);
62 $this->cj_path = $this->cj_array[
'file_info'][
'path'];
63 $this->cj_file = $this->cj_array[
'file_info'][
'file'];
64 $this->cj_key = $this->cj_array[
'file_info'][
'key'];
65 $this->cj_interval = $this->cj_array[
'file_info'][
'interval'];
67 if(!isset($_SESSION[
'last_cronjob']))
69 $_SESSION[
'last_cronjob'] = $_SESSION[
'SESSION_STARTED'] - ($this->cj_interval +1);
72 if(strlen($this->cj_key) < AUTH_MIN_PASS_LENGTH)
74 die (
LEPTON_tools::display(
'NOT allowed: key must have a min of chars ("AUTH_MIN_PASS_LENGTH") in cronjob.ini.php',
'pre',
'ui red message'));
77 if(!file_exists(LEPTON_PATH.$this->cj_path.$this->cj_file) )
79 die (
LEPTON_tools::display(
'You have to specify a correct file in cronjob.ini.php to use this class!',
'pre',
'ui red message'));