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 +}