From 0710d779f1ed72b4d454c64fe26553517805f80a Mon Sep 17 00:00:00 2001 From: Kasim Necdet Percinel Date: Mon, 18 Nov 2024 23:43:11 +0000 Subject: [PATCH] fix deprecated usage of strftime --- docroot/index.php | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/docroot/index.php b/docroot/index.php index 97c12d79..239660f1 100644 --- a/docroot/index.php +++ b/docroot/index.php @@ -285,9 +285,13 @@ function printHTMLErrorMsg($msg) { \n"; - printf($meta, strftime('%Y-%m-%d %H:%m:%S'), $_SERVER['HTTP_HOST'], - $_SERVER['REQUEST_URI']); + // Find out http or https + $protocol = (!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] == 'on') ? 'https' : 'http'; + + // Debug information + $meta = "\n"; + printf($meta, date('Y-m-d H:m:s'), $_SERVER['HTTP_HOST'], $_SERVER['REQUEST_URI']); + ?> Helioviewer.org API - Error