Use __dir__ to find resources/require.php

This commit is contained in:
markjcrane
2023-06-16 22:49:09 -06:00
parent d4231ab0e1
commit 32051873be
21 changed files with 36 additions and 92 deletions

View File

@@ -24,12 +24,8 @@
//check the permission
if (defined('STDIN')) {
//set the include path
$conf = glob("{/usr/local/etc,/etc}/fusionpbx/config.conf", GLOB_BRACE);
set_include_path(parse_ini_file($conf[0])['document.root']);
//includes files
require_once "resources/require.php";
require_once dirname(__DIR__, 4) . "/resources/require.php";
}
else {
//only allow running this from command line