From 94c23185b1d0d95bb44cfd6f889f1a6ca166bb57 Mon Sep 17 00:00:00 2001 From: monaco Date: Sat, 15 May 2021 19:54:09 +0200 Subject: Update archive.php --- archive.php | 26 +++++++++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/archive.php b/archive.php index 4b43a8b..54bd4a1 100644 --- a/archive.php +++ b/archive.php @@ -64,15 +64,35 @@ echo "
";
Paste | Archive

"; + +?> + + 15, // how many item to display for each page - 'around' => 2, // how many page btn to show around the current page btn + 'quantity' => 30, // how many item to display for each page + 'around' => 7, // how many page btn to show around the current page btn 'directory' => './p', // dir to scan for items ); $page = isset($_GET['page']) ? $_GET['page'] : 1; $offset = ($page - 1) * $options['quantity']; // $page base index is 1 - $filelist = array_diff(scandir($options['directory']), array('..', '.','index.txt')); + $filelist = array_diff(scandir($options['directory']), array('..', '.')); //get subset of file array $selectedFiles = array_slice($filelist, $offset, $options['quantity']); -- cgit v1.2.3