From 51d27c6f1ca3e8b2bab00993526f1eb686e4477f Mon Sep 17 00:00:00 2001 From: Matthieu Bessat Date: Sun, 8 Aug 2021 20:54:01 +0200 Subject: [PATCH] fix: add list to quicknote and quickupload --- modules/logator/logator.php | 18 ------------------ modules/quicknote/quicknote.php | 21 +++++++++++++++++++++ modules/quickupload/quickupload.php | 17 +++++++++++++++++ utils.php | 18 ++++++++++++++++++ 4 files changed, 56 insertions(+), 18 deletions(-) diff --git a/modules/logator/logator.php b/modules/logator/logator.php index 611a9d9..68b9d7e 100644 --- a/modules/logator/logator.php +++ b/modules/logator/logator.php @@ -1,23 +1,5 @@ +

List of messages

+ + +

List of uploaded files

+ + microtime() ]; } + +function getFilesAsArray($path) { + $dirs = array_filter(glob($path . '/*'), 'is_file'); + $dirs = array_map(function ($dirName) { + $compo = explode('/', $dirName); + return $compo[count($compo)-1]; + }, $dirs); + return array_values($dirs); +} + +function getDirsAsArray($path) { + $dirs = array_filter(glob($path . '/*'), 'is_dir'); + $dirs = array_map(function ($dirName) { + $compo = explode('/', $dirName); + return $compo[count($compo)-1]; + }, $dirs); + return array_values($dirs); +}