From: Patrick Canterino Date: Sat, 12 Oct 2024 14:48:50 +0000 (+0000) Subject: Removed the download button and the corresponding link for encrypted files from the... X-Git-Url: https://git.p6c8.net/jirafeau.git/commitdiff_plain/a37a6ed33d07882e4259a6cd2a570893b0057bbf Removed the download button and the corresponding link for encrypted files from the admin interface --- diff --git a/lib/functions.php b/lib/functions.php index 83d7a2d..f70e0de 100644 --- a/lib/functions.php +++ b/lib/functions.php @@ -744,7 +744,7 @@ function jirafeau_get_link($hash) } /** - * List files ii folder in admin interface. + * List files in admin interface. */ function jirafeau_admin_list($name, $file_hash, $link_hash) { @@ -780,25 +780,39 @@ function jirafeau_admin_list($name, $file_hash, $link_hash) } /* Print link information. */ echo ''; - echo '' . - '' . jirafeau_escape($l['file_name']) . '
'; + echo ''; + + if (!$l['crypted'] && !$l['crypted_legacy']) { + echo'' . jirafeau_escape($l['file_name']) . ''; + } + else { + echo jirafeau_escape($l['file_name']); + } + + echo '
'; + echo t('TYPE') . ': ' . jirafeau_escape($l['mime_type']) . '
'; echo t('SIZE') . ': ' . jirafeau_human_size($l['file_size']) . '
'; echo t('EXPIRE') . ': ' . ($l['time'] == -1 ? '∞' : jirafeau_get_datetimefield($l['time'])) . '
'; - echo t('ONETIME') . ': ' . ($l['onetime'] == 'O' ? 'Yes' : 'No') . '
'; + echo t('ONETIME') . ': ' . ($l['onetime'] == 'O' ? t('YES') : t('NO')) . '
'; + echo t('ENCRYPTED') . ': ' . (($l['crypted'] || $l['crypted_legacy']) ? t('YES') : t('NO')) . '
'; echo t('UPLOAD_DATE') . ': ' . jirafeau_get_datetimefield($l['upload_date']) . '
'; if (strlen($l['ip']) > 0) { echo t('ORIGIN') . ': ' . $l['ip'] . '
'; } echo ''; + + if (!$l['crypted'] && !$l['crypted_legacy']) { + echo '
' . + '' . + '' . + jirafeau_admin_csrf_field() . + '' . + '
'; + } + echo '
' . - '' . - '' . - jirafeau_admin_csrf_field() . - '' . - '
' . - '
' . '' . '' . jirafeau_admin_csrf_field() . diff --git a/lib/locales/ar.json b/lib/locales/ar.json index f8a9ad6..83227b4 100644 --- a/lib/locales/ar.json +++ b/lib/locales/ar.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/be.json b/lib/locales/be.json index 1fa1e6f..4dc371c 100644 --- a/lib/locales/be.json +++ b/lib/locales/be.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/bn_IN.json b/lib/locales/bn_IN.json index 4c86aef..c0d7a26 100644 --- a/lib/locales/bn_IN.json +++ b/lib/locales/bn_IN.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/bo.json b/lib/locales/bo.json index 353cbd5..9d08b73 100644 --- a/lib/locales/bo.json +++ b/lib/locales/bo.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/ca.json b/lib/locales/ca.json index 900d618..2d259b9 100644 --- a/lib/locales/ca.json +++ b/lib/locales/ca.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/ckb.json b/lib/locales/ckb.json index f4f30fe..bbc76bc 100644 --- a/lib/locales/ckb.json +++ b/lib/locales/ckb.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/cs.json b/lib/locales/cs.json index a310461..9db9731 100644 --- a/lib/locales/cs.json +++ b/lib/locales/cs.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/da.json b/lib/locales/da.json index 645bcef..af0ccb8 100644 --- a/lib/locales/da.json +++ b/lib/locales/da.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/de.json b/lib/locales/de.json index 76062b5..8936ee1 100644 --- a/lib/locales/de.json +++ b/lib/locales/de.json @@ -1,4 +1,7 @@ { + "NO": "Nein", + "YES": "Ja", + "ENCRYPTED": "Verschlüsselt", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/el.json b/lib/locales/el.json index d9ea2f5..2676b18 100644 --- a/lib/locales/el.json +++ b/lib/locales/el.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/en.json b/lib/locales/en.json index aa7559d..f17bf9a 100644 --- a/lib/locales/en.json +++ b/lib/locales/en.json @@ -1,4 +1,7 @@ { + "NO": "No", + "YES": "Yes", + "ENCRYPTED": "Encrypted", "SODIUM_UNAVAILABLE": "Encryption is enabled in configuration, but the Sodium PHP module is not loaded! Encryption is not available!", "ADMIN_FOLDER_INFO": "(File must be in Folder %s)", "ADMIN_FILE_SELECT": "Filename", diff --git a/lib/locales/es.json b/lib/locales/es.json index 339c468..3c6bac0 100644 --- a/lib/locales/es.json +++ b/lib/locales/es.json @@ -1,4 +1,7 @@ { + "NO": "No", + "YES": "Sí", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/et.json b/lib/locales/et.json index f4f30fe..bbc76bc 100644 --- a/lib/locales/et.json +++ b/lib/locales/et.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/fi.json b/lib/locales/fi.json index 21c28d1..debff9c 100644 --- a/lib/locales/fi.json +++ b/lib/locales/fi.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/fr.json b/lib/locales/fr.json index 9850683..8629b76 100644 --- a/lib/locales/fr.json +++ b/lib/locales/fr.json @@ -1,4 +1,7 @@ { + "NO": "Non", + "YES": "Oui", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/he.json b/lib/locales/he.json index f5c72b6..ea0f4e5 100644 --- a/lib/locales/he.json +++ b/lib/locales/he.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/hi.json b/lib/locales/hi.json index 9349097..fdca622 100644 --- a/lib/locales/hi.json +++ b/lib/locales/hi.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/hr.json b/lib/locales/hr.json index fb75482..d1994d6 100644 --- a/lib/locales/hr.json +++ b/lib/locales/hr.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/hu.json b/lib/locales/hu.json index a381b82..a4a075e 100644 --- a/lib/locales/hu.json +++ b/lib/locales/hu.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/id.json b/lib/locales/id.json index 4ed9761..24cea50 100644 --- a/lib/locales/id.json +++ b/lib/locales/id.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/it.json b/lib/locales/it.json index 2b8600b..4be5d53 100644 --- a/lib/locales/it.json +++ b/lib/locales/it.json @@ -1,4 +1,7 @@ { + "NO": "No", + "YES": "Sì", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/ja.json b/lib/locales/ja.json index 0a39a65..04e6735 100644 --- a/lib/locales/ja.json +++ b/lib/locales/ja.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/ko.json b/lib/locales/ko.json index 9349097..fdca622 100644 --- a/lib/locales/ko.json +++ b/lib/locales/ko.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/la.json b/lib/locales/la.json index e1b1bce..b5cf0a2 100644 --- a/lib/locales/la.json +++ b/lib/locales/la.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/mfe.json b/lib/locales/mfe.json index f4f30fe..bbc76bc 100644 --- a/lib/locales/mfe.json +++ b/lib/locales/mfe.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/ms.json b/lib/locales/ms.json index e97fa01..27575f7 100644 --- a/lib/locales/ms.json +++ b/lib/locales/ms.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/nb_NO.json b/lib/locales/nb_NO.json index c5a6297..939f52b 100644 --- a/lib/locales/nb_NO.json +++ b/lib/locales/nb_NO.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/nl.json b/lib/locales/nl.json index ca4aa74..c817eee 100644 --- a/lib/locales/nl.json +++ b/lib/locales/nl.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/pl.json b/lib/locales/pl.json index 6a1fa9a..d70f0de 100644 --- a/lib/locales/pl.json +++ b/lib/locales/pl.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/ps.json b/lib/locales/ps.json index f4f30fe..bbc76bc 100644 --- a/lib/locales/ps.json +++ b/lib/locales/ps.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/pt.json b/lib/locales/pt.json index f326529..812b59d 100644 --- a/lib/locales/pt.json +++ b/lib/locales/pt.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/pt_BR.json b/lib/locales/pt_BR.json index 638dc08..1e36b53 100644 --- a/lib/locales/pt_BR.json +++ b/lib/locales/pt_BR.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/ro.json b/lib/locales/ro.json index fe03dec..6d76460 100644 --- a/lib/locales/ro.json +++ b/lib/locales/ro.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/ru.json b/lib/locales/ru.json index e9dc7f1..6b0f951 100644 --- a/lib/locales/ru.json +++ b/lib/locales/ru.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/sh.json b/lib/locales/sh.json index f4f30fe..bbc76bc 100644 --- a/lib/locales/sh.json +++ b/lib/locales/sh.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/si.json b/lib/locales/si.json index eb4a94d..842db6c 100644 --- a/lib/locales/si.json +++ b/lib/locales/si.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/sk.json b/lib/locales/sk.json index a69e18d..8c42dc5 100644 --- a/lib/locales/sk.json +++ b/lib/locales/sk.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/sl.json b/lib/locales/sl.json index bb4c65d..463d58b 100644 --- a/lib/locales/sl.json +++ b/lib/locales/sl.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/sq.json b/lib/locales/sq.json index f4f30fe..bbc76bc 100644 --- a/lib/locales/sq.json +++ b/lib/locales/sq.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/sr.json b/lib/locales/sr.json index 7755688..6aca55f 100644 --- a/lib/locales/sr.json +++ b/lib/locales/sr.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/sv.json b/lib/locales/sv.json index 8399753..59c215b 100644 --- a/lib/locales/sv.json +++ b/lib/locales/sv.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/ta.json b/lib/locales/ta.json index 58c4f51..c46fd97 100644 --- a/lib/locales/ta.json +++ b/lib/locales/ta.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/template.json b/lib/locales/template.json index ee38ca9..ce688bf 100644 --- a/lib/locales/template.json +++ b/lib/locales/template.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "SODIUM_UNAVAILABLE": "", "ADMIN_FOLDER_INFO": "", "ADMIN_FILE_SELECT": "", diff --git a/lib/locales/th.json b/lib/locales/th.json index f4f30fe..bbc76bc 100644 --- a/lib/locales/th.json +++ b/lib/locales/th.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/tr.json b/lib/locales/tr.json index c29255e..76287db 100644 --- a/lib/locales/tr.json +++ b/lib/locales/tr.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/uk.json b/lib/locales/uk.json index f609ac8..bd8f31c 100644 --- a/lib/locales/uk.json +++ b/lib/locales/uk.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/vi.json b/lib/locales/vi.json index 4dfcf33..35bb24e 100644 --- a/lib/locales/vi.json +++ b/lib/locales/vi.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/zh.json b/lib/locales/zh.json index 43495b1..5b01550 100644 --- a/lib/locales/zh.json +++ b/lib/locales/zh.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "", diff --git a/lib/locales/zh_TW.json b/lib/locales/zh_TW.json index 2e8bbf7..43877f5 100644 --- a/lib/locales/zh_TW.json +++ b/lib/locales/zh_TW.json @@ -1,4 +1,7 @@ { + "NO": "", + "YES": "", + "ENCRYPTED": "", "DOWNLOAD_IP": "", "DOWNLOAD_DATE": "", "DOWNLOAD_COUNT": "",