From fd0615587ec4bcbde0c220d22d64058c5df7adbc Mon Sep 17 00:00:00 2001 From: FusionPBX Date: Mon, 8 May 2023 19:02:58 -0600 Subject: [PATCH] Update require.php --- resources/require.php | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/resources/require.php b/resources/require.php index 6c12bee0a6..01cab5af15 100644 --- a/resources/require.php +++ b/resources/require.php @@ -30,17 +30,18 @@ set_include_path($conf['document.root']); //set the server variables and define project path constant - $_SERVER["DOCUMENT_ROOT"] = $conf['document.root']; - $_SERVER["PROJECT_ROOT"] = $conf['document.root']; - if (isset($conf['project.path'])) { - $_SERVER["PROJECT_ROOT"] = $conf['document.root'].'/'.$conf['project.path']; - define("PROJECT_ROOT", $conf['document.root'].'/'.$conf['project.path']); - define("PROJECT_PATH", $conf['project.path']); - } - else { - define("PROJECT_ROOT", $conf['document.root']); - define("PROJECT_PATH", $conf['document.root']); - } + $_SERVER["DOCUMENT_ROOT"] = $conf['document.root']; + $_SERVER["PROJECT_ROOT"] = $conf['document.root']; + $_SERVER["PROJECT_PATH"] = $conf['project.path']; + if (isset($conf['project.path'])) { + $_SERVER["PROJECT_ROOT"] = $conf['document.root'].'/'.$conf['project.path']; + define("PROJECT_ROOT", $conf['document.root'].'/'.$conf['project.path']); + define("PROJECT_PATH", $conf['project.path']); + } + else { + define("PROJECT_ROOT", $conf['document.root']); + define("PROJECT_PATH", ''); + } //set the error reporting ini_set('display_errors', '1');