summaryrefslogtreecommitdiffstats
path: root/application/controllers/file.php
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2016-06-17 00:06:33 +0200
committerFlorian Pritz <bluewind@xinu.at>2016-07-04 07:58:15 +0200
commitaca5b6c6362c415df501f76ef170794e77522242 (patch)
tree30dbb50be348d6d5ffcd81363fcb1b9ec372b226 /application/controllers/file.php
parent8deb80b8d2c1c8d6f9831a777939d6d5da52a71a (diff)
file/history: Add support to display preview of entries on hover
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'application/controllers/file.php')
-rw-r--r--application/controllers/file.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/application/controllers/file.php b/application/controllers/file.php
index 79d5395ae..1f07ae4ec 100644
--- a/application/controllers/file.php
+++ b/application/controllers/file.php
@@ -764,6 +764,11 @@ class File extends MY_Controller {
foreach($history["items"] as $key => $item) {
$history["items"][$key]["filesize"] = format_bytes($item["filesize"]);
+
+ if (isset($item['preview_text'])) {
+ $history["items"][$key]["preview_text"] = htmlentities($item['preview_text']);
+ }
+
if (is_cli_client()) {
// Keep track of longest string to pad plaintext output correctly
foreach($fields as $length_key => $value) {