From a1558f687ada95c29d52e341031de4793876c41d Mon Sep 17 00:00:00 2001 From: Per Qvarforth Date: Sun, 13 Feb 2022 20:40:56 +0000 Subject: [PATCH] fixed view path --- htdocs/includes/common.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/includes/common.php b/htdocs/includes/common.php index f8773e2..cb25dc6 100644 --- a/htdocs/includes/common.php +++ b/htdocs/includes/common.php @@ -1789,7 +1789,7 @@ function getView($request) { $view = array_pop($parts); $dir = array_pop($parts); if ($view && $dir == 'views') { - $path = "${_SERVER["DOCUMENT_ROOT"]}/public/views"; + $path = ROOT . '/public/views'; foreach (scandir($path) as $file) { if ($file == $view) { return "$path/$view"; @@ -1813,4 +1813,4 @@ function getWebsiteConfig($key) { } return null; -} \ No newline at end of file +}