diff --git a/e107_admin/cron.php b/e107_admin/cron.php index 726b6e9e07..32a8a494b3 100644 --- a/e107_admin/cron.php +++ b/e107_admin/cron.php @@ -68,7 +68,7 @@ class cron_admin_ui extends e_admin_ui 'cron_description' => array('title'=> LAN_DESCRIPTION, 'type' => 'text', 'data'=>'str', 'width' => '35%', 'readonly' => 1), 'cron_function' => array('title'=> LAN_CRON_2, 'type' => 'text', 'data'=>'str', 'width' => 'auto', 'thclass' => 'left first', 'readonly' => 1), 'cron_tab' => array('title'=> LAN_CRON_3, 'type' => 'method', 'width' => 'auto'), // Display name - 'cron_lastrun' => array('title'=> LAN_CRON_4, 'type' => 'datestamp', 'data' => 'int', 'width' => 'auto', 'readonly' => 2), + 'cron_lastrun' => array('title'=> LAN_CRON_4, 'type' => 'datestamp', 'data' => 'int', 'width' => 'auto', 'readonly' => 2, 'readParms'=>['mask'=>'dd MM yyyy hh:ii:ss']), 'cron_active' => array('title'=> LAN_ACTIVE, 'type' => 'boolean', 'data'=> 'int', 'thclass' => 'center', 'class'=>'center', 'filter' => true, 'batch' => true, 'width' => 'auto'), 'options' => array('title'=> LAN_OPTIONS, 'type' => 'method', 'data'=> null, 'noedit'=>TRUE, 'forced'=>TRUE, 'width' => '10%', 'thclass' => 'center last', 'class' => 'right') ); diff --git a/e107_handlers/Shims/Internal/StrftimeTrait.php b/e107_handlers/Shims/Internal/StrftimeTrait.php index bfa5083c36..387eb8ef07 100644 --- a/e107_handlers/Shims/Internal/StrftimeTrait.php +++ b/e107_handlers/Shims/Internal/StrftimeTrait.php @@ -65,11 +65,13 @@ protected static function date_format($datetime, $format) return date_format($datetime, $format); } + + $timezone = 'GMT'.date('O'); $formatter = new \IntlDateFormatter( self::getSensibleLocale(), \IntlDateFormatter::NONE, \IntlDateFormatter::NONE, - 'GMT'.date('O'), // More accurate timezone. @see https://stackoverflow.com/questions/31707395/why-php-intldateformatter-returns-wrong-date-1-hour + $timezone, // More accurate timezone. @see https://stackoverflow.com/questions/31707395/why-php-intldateformatter-returns-wrong-date-1-hour null, $format ); diff --git a/e107_handlers/cron_class.php b/e107_handlers/cron_class.php index bbc5a2266d..0eb14d215e 100644 --- a/e107_handlers/cron_class.php +++ b/e107_handlers/cron_class.php @@ -1223,16 +1223,12 @@ public function runJob($job) { if($this->debug) { - $this->cron->debug('e107: Cron could not find method: '.$job['function'], E_ERROR); + $this->cron->debug('Cron could not find method: '.$job['function'], E_ERROR); } return $status; } - if($this->debug) - { - $this->cron->debug('e107: Cron could not find method: '.$class . "::" . $job['function'].'()', E_NOTICE); - } // Exception handling. $method = $job['function'];