mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2025-12-30 00:53:50 +00:00
Replace the DOCUMENT_ROOT and PROJECT_ROOT variables
Use the __DIR__ constant and dirname as needed
This commit is contained in:
@@ -1584,7 +1584,7 @@ class xml_cdr {
|
||||
|| '+' . ($value['destination_prefix'] ?? '') . ($value['destination_area_code'] ?? '') . $value['destination_number'] == $detail_action
|
||||
|| ($value['destination_prefix'] ?? '') . ($value['destination_area_code'] ?? '') . $value['destination_number'] == $detail_action
|
||||
|| ($value['destination_area_code'] ?? '') . $value['destination_number'] == $detail_action) {
|
||||
if (file_exists($_SERVER["PROJECT_ROOT"] . "/app/" . $application . "/app_languages.php")) {
|
||||
if (file_exists(dirname(__DIR__, 4) . "/app/" . $application . "/app_languages.php")) {
|
||||
$value['application'] = $application;
|
||||
return $value;
|
||||
}
|
||||
@@ -1593,7 +1593,7 @@ class xml_cdr {
|
||||
|
||||
//find all other matching actions
|
||||
if (!empty($value['extension']) && $value['extension'] == $detail_action || preg_match('/^' . preg_quote($value['extension'] ?? '') . '$/', $detail_action)) {
|
||||
if (file_exists($_SERVER["PROJECT_ROOT"] . "/app/" . $application . "/app_languages.php")) {
|
||||
if (file_exists(dirname(__DIR__, 4) . "/app/" . $application . "/app_languages.php")) {
|
||||
$value['application'] = $application;
|
||||
return $value;
|
||||
}
|
||||
|
||||
@@ -833,7 +833,7 @@
|
||||
if (is_array($result)) {
|
||||
|
||||
//determine if theme images exist
|
||||
$theme_image_path = $_SERVER["DOCUMENT_ROOT"]."/themes/".$settings->get('domain', 'template', 'default')."/images/";
|
||||
$theme_image_path = dirname(__DIR__, 2)."/themes/".$settings->get('domain', 'template', 'default')."/images/";
|
||||
$theme_cdr_images_exist = (
|
||||
file_exists($theme_image_path."icon_cdr_inbound_answered.png") &&
|
||||
file_exists($theme_image_path."icon_cdr_inbound_no_answer.png") &&
|
||||
|
||||
Reference in New Issue
Block a user