tinyfilemanager
tinyfilemanager copied to clipboard
Renaming folders?
Discussed in https://github.com/prasathmani/tinyfilemanager/discussions/858
Originally posted by redherring917b September 20, 2022 Hi there.
I find myself unable to rename an existing folder. I had a similar issue with renaming files, until I realized that I had to add to my allowed list of $allowed_file_extensions in the config.php file that I'm using. But allowing extensions wouldn't apply to folders, obviously. Any thoughts on how to successfully rename a folder?
EDITED: To perhaps be clearer, when attempting to rename a folder I'm just getting the "Error while renaming from [oldname] to [newname]" message, so it would seem to be failing on this condition in tinyfilemanager.php:
if (fm_rename($path . '/' . $old, $path . '/' . $new)) {
I've output both the old and new paths and they are identical save for the changed folder name.
Thanks!