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:
@@ -446,8 +446,8 @@ if (!empty($_POST) && empty($_POST["persistformvar"])) {
|
||||
echo " <select class='formfld' id='user_setting_value' name='user_setting_value' style=''>\n";
|
||||
echo " <option value=''></option>\n";
|
||||
//add all the themes to the list
|
||||
$theme_dir = $_SERVER["DOCUMENT_ROOT"].PROJECT_PATH.'/themes';
|
||||
if ($handle = opendir($_SERVER["DOCUMENT_ROOT"].PROJECT_PATH.'/themes')) {
|
||||
$theme_dir = dirname(__DIR__, 2).'/themes';
|
||||
if ($handle = opendir(dirname(__DIR__, 2).'/themes')) {
|
||||
while (false !== ($dir_name = readdir($handle))) {
|
||||
if ($dir_name != "." && $dir_name != ".." && $dir_name != ".svn" && $dir_name != ".git" && is_dir($theme_dir.'/'.$dir_name)) {
|
||||
$dir_label = str_replace('_', ' ', $dir_name);
|
||||
|
||||
Reference in New Issue
Block a user