From 3956305d463b8272880f8c69b24c572cf5591873 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=AE=E3=81=B6?= Date: Mon, 6 Dec 2021 16:53:00 +0900 Subject: [PATCH] ref #497 Use of undefined constant --- data/class/SC_Initial.php | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/data/class/SC_Initial.php b/data/class/SC_Initial.php index 11aecb16f5..83c5aa204e 100644 --- a/data/class/SC_Initial.php +++ b/data/class/SC_Initial.php @@ -77,8 +77,32 @@ public function requireInitialConfig() copy(realpath(dirname(__FILE__)) . '/../../tests/config.php', CONFIG_REALFILE); require_once CONFIG_REALFILE; + } else if (!GC_Utils_Ex::isInstallFunction()){ + + // PHP8対応 + if (!defined("HTTP_URL")) { + define ('HTTP_URL', ''); + define ('HTTPS_URL', ''); + define ('ROOT_URLPATH', ''); + define ('DOMAIN_NAME', ''); + define ('DB_TYPE', ''); + define ('DB_USER', ''); + define ('DB_PASSWORD', ''); + define ('DB_SERVER', ''); + define ('DB_NAME', ''); + define ('DB_PORT', ''); + define ('ADMIN_DIR', ''); + define ('ADMIN_FORCE_SSL', ""); + define ('ADMIN_ALLOW_HOSTS', ''); + define ('AUTH_MAGIC', ''); + define ('PASSWORD_HASH_ALGOS', 'sha256'); + define ('MAIL_BACKEND', 'mail'); + define ('SMTP_HOST', ''); + define ('SMTP_PORT', ''); + define ('SMTP_USER', ''); + define ('SMTP_PASSWORD', ''); + } } - } /**