Merge branch 'ent-3990-7999-colecciones-no-funcionan-no-se-puede-subir-ni-crear-archivos' into 'develop'

fixed filemanager

See merge request artica/pandorafms!2408
This commit is contained in:
Daniel Rodriguez 2019-05-08 18:26:23 +02:00
commit 0a7539cc3a
4 changed files with 5 additions and 15 deletions

View File

@ -242,7 +242,6 @@ if ($filemanager) {
$chunck_url = '&create=1';
}
$homedir_filemanager = isset($config['homedir_filemanager']) ? $config['homedir_filemanager'] : false;
filemanager_file_explorer(
$real_directory,
$directory,
@ -253,7 +252,7 @@ if ($filemanager) {
'index.php?sec=gservers&sec2=godmode/servers/plugin'.$chunck_url.'&plugin_command=[FILE_FULLPATH]&id_plugin='.$id_plugin,
true,
0775,
$homedir_filemanager
false
);
}

View File

@ -66,8 +66,6 @@ $real_directory = realpath($config['homedir'].'/'.$directory);
echo '<h4>'.__('Index of %s', $directory).'</h4>';
$homedir_filemanager = isset($config['homedir_filemanager']) ? $config['homedir_filemanager'] : false;
filemanager_file_explorer(
$real_directory,
$directory,
@ -78,5 +76,5 @@ filemanager_file_explorer(
'',
false,
'',
$homedir_filemanager
false
);

View File

@ -120,18 +120,13 @@ if (!function_exists('mime_content_type')) {
global $config;
if (isset($config['homedir_filemanager'])) {
$homedir_filemanager = trim(io_safe_output($config['homedir_filemanager']));
} else {
$homedir_filemanager = trim($config['homedir']);
}
$homedir_filemanager = trim($config['homedir']);
$sec2 = get_parameter('sec2');
if ($sec2 == 'enterprise/godmode/agentes/collections' || $sec2 == 'advanced/collections') {
$homedir_filemanager .= '/attachment/collection/';
}
$upload_file_or_zip = (bool) get_parameter('upload_file_or_zip');
if ($upload_file_or_zip) {
@ -738,6 +733,7 @@ function filemanager_file_explorer(
$data[4] .= html_print_input_hidden('delete_file', 1, true);
$relative_dir = str_replace($homedir_filemanager, '', str_replace('\\', '/', dirname($fileinfo['realpath'])));
if ($relative_dir[0] == '/') {
$relative_dir = substr($relative_dir, 1);
}

View File

@ -69,9 +69,6 @@ $real_directory = realpath($config['homedir'].'/'.$directory);
ui_print_info_message(__('MIB files will be installed on the system. Please note that a MIB may depend on other MIB. To customize trap definitions use the SNMP trap editor.'));
// echo '<h4>' . __('Index of %s', $directory) . '</h4>';
$homedir_filemanager = isset($config['homedir_filemanager']) ? $config['homedir_filemanager'] : false;
filemanager_file_explorer(
$real_directory,
$directory,
@ -82,5 +79,5 @@ filemanager_file_explorer(
'',
false,
'',
$homedir_filemanager
false
);