From dd6f33afdfb0f4c775e14098eb7df08a010b7da4 Mon Sep 17 00:00:00 2001 From: BANKA2017 <17263253+BANKA2017@users.noreply.github.com> Date: Wed, 14 Jun 2023 15:30:29 +0800 Subject: [PATCH] fix: #52 Does not respect directory tree while uploading a folder containing sub-folders --- tinyfilemanager.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tinyfilemanager.php b/tinyfilemanager.php index 71786c9..a5056c3 100644 --- a/tinyfilemanager.php +++ b/tinyfilemanager.php @@ -954,7 +954,7 @@ if (!empty($_FILES) && !FM_READONLY) { $targetPath = $path . $ds; if ( is_writable($targetPath) ) { - $fullPath = $path . '/' . basename($fullPathInput); + $fullPath = $path . '/' . $fullPathInput; $folder = substr($fullPath, 0, strrpos($fullPath, "/")); if (!is_dir($folder)) {