diff --git a/classes/config.php b/classes/config.php index ab31bc860..9a8b466ab 100644 --- a/classes/config.php +++ b/classes/config.php @@ -299,6 +299,13 @@ class Config { return self::get_instance()->_get_version($as_string); } + // returns version showing (if possible) full timestamp of commit id + static function get_version_html() : string { + $version = self::get_version(false); + + return sprintf("%s", date("Y-m-d H:i:s", ($version['timestamp'] ?? 0)), $version['version']); + } + /** * @return array|string */ @@ -363,7 +370,7 @@ class Config { if ($check == "version") { - $rv["version"] = date("y.m", (int)$timestamp) . "-$commit"; + $rv["version"] = sprintf("%s-%s", date("y.m", (int)$timestamp), $commit); $rv["commit"] = $commit; $rv["timestamp"] = $timestamp; diff --git a/prefs.php b/prefs.php index 36641e0f3..0a944e712 100644 --- a/prefs.php +++ b/prefs.php @@ -170,7 +170,7 @@