From a7cfa4648f08ced59c9a76b464cb135fe1e01571 Mon Sep 17 00:00:00 2001 From: Florian Pritz Date: Sun, 18 Dec 2011 10:07:13 +0100 Subject: display more information on delete_form Signed-off-by: Florian Pritz --- application/controllers/file.php | 6 ++++++ application/views/file/delete_form.php | 38 +++++++++++++++++++++++++++++----- 2 files changed, 39 insertions(+), 5 deletions(-) (limited to 'application') diff --git a/application/controllers/file.php b/application/controllers/file.php index de2ce314b..d14e4879a 100644 --- a/application/controllers/file.php +++ b/application/controllers/file.php @@ -165,6 +165,12 @@ class File extends CI_Controller { $password = $this->file_mod->get_password(); $data["title"] = "Delete"; $data["id"] = $id; + + $data["filedata"] = $this->file_mod->get_filedata($id); + if ($data["filedata"]) { + $data["filedata"]["size"] = filesize($this->file_mod->file($data["filedata"]["hash"])); + } + if ($id && !$this->file_mod->id_exists($id)) { $data["msg"] = "Unkown ID."; } elseif ($password != "NULL") { diff --git a/application/views/file/delete_form.php b/application/views/file/delete_form.php index b9819a7c5..f617d25c7 100644 --- a/application/views/file/delete_form.php +++ b/application/views/file/delete_form.php @@ -1,9 +1,37 @@
-

- "; ?> - Password: - -

+ ".$msg."

"; ?> +

You are about to delete the following upload:

+ + + + + + + + + + + + + + + + + + + + + + + + + + + +
ID
Filename
Date of upload
Size
Mimetype
Password + + +
-- cgit v1.2.3-24-g4f1b