Skip to content
This repository was archived by the owner on Nov 15, 2024. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions filemanager/config/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,9 @@
'replace_with' => "_",
//convert to lowercase the files and folders name
'lower_case' => false,
//Should we rename (translitareation and convert_space) files that are already on the filesystem (true)
//or only the news files (false => keeps the existing files and folders intact)
'fix_existing_files' => true,

//Add ?484899493349 (time value) to returned images to prevent cache
'add_time_to_img' => false,
Expand Down
4 changes: 2 additions & 2 deletions filemanager/dialog.php
Original file line number Diff line number Diff line change
Expand Up @@ -1035,7 +1035,7 @@ function extensionSort($x, $y)
continue;
}
$new_name=fix_filename($file,$config);
if($ftp && $file!='..' && $file!=$new_name){
if($ftp && $file!='..' && $file!=$new_name && !empty($config['fix_existing_files']){
//rename
rename_folder($config['current_path'].$subdir.$file,$new_name,$ftp,$config);
$file=$new_name;
Expand Down Expand Up @@ -1138,7 +1138,7 @@ function extensionSort($x, $y)
$file_path=$config['current_path'].$rfm_subfolder.$subdir.$file;
//check if file have illegal caracter

if($file!=fix_filename($file,$config)){
if(!empty($config['fix_existing_files'] && $file!=fix_filename($file,$config)){
$file1=fix_filename($file,$config);
$file_path1=($config['current_path'].$rfm_subfolder.$subdir.$file1);
if(file_exists($file_path1)){
Expand Down