diff --git a/web/app/controllers/tinyfilemanager/tinyfilemanager.php b/web/app/controllers/tinyfilemanager/tinyfilemanager.php index aa0bbd4..e17689c 100644 --- a/web/app/controllers/tinyfilemanager/tinyfilemanager.php +++ b/web/app/controllers/tinyfilemanager/tinyfilemanager.php @@ -809,7 +809,7 @@ if (!empty($_FILES) && !FM_READONLY) { $targetPath = $path . $ds; if ( is_writable($targetPath) ) { - $fullPath = $path . '/' . basename($fullPathInput); + $fullPath = $path . '/' . array_pop(explode("/", $fullPathInput)); $folder = substr($fullPath, 0, strrpos($fullPath, "/")); if(file_exists ($fullPath) && !$override_file_name && !$chunks) {