From c5187160be16af5c5574a020ff83e7da586c4338 Mon Sep 17 00:00:00 2001 From: Jerome Jutteau Date: Wed, 2 Jan 2013 21:42:42 +0100 Subject: [PATCH] fix admin searches --- lib/functions.php | 10 +++++----- lib/lang/fr.php | 2 ++ 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/lib/functions.php b/lib/functions.php index 6d7cb34..97733d5 100644 --- a/lib/functions.php +++ b/lib/functions.php @@ -446,11 +446,11 @@ jirafeau_admin_list ($name, $file_hash, $link_hash) { echo '
'; if (!empty ($name)) - echo $name . ' '; + echo t('Filename') . ": $name "; if (!empty ($file_hash)) - echo $file_hash . ' '; + echo t('file') . ": $file_hash "; if (!empty ($link_hash)) - echo $link_hash . ' '; + echo t('link') . ": $link_hash "; if (empty ($name) && empty ($file_hash) && empty ($link_hash)) echo t('List all files'); echo ''; @@ -489,11 +489,11 @@ jirafeau_admin_list ($name, $file_hash, $link_hash) continue; /* Filter. */ - if (!empty ($name) && $name != $l['file_name']) + if (!empty ($name) && !preg_match ("/$name/i", $l['file_name'])) continue; if (!empty ($file_hash) && $file_hash != $l['md5']) continue; - if (!empty ($link_hash) && $link_hash != $link) + if (!empty ($link_hash) && $link_hash != $node) continue; /* Print link informations. */ echo ''; diff --git a/lib/lang/fr.php b/lib/lang/fr.php index d266c1f..49ec634 100755 --- a/lib/lang/fr.php +++ b/lib/lang/fr.php @@ -112,6 +112,8 @@ $tr = array ( 'You are now Logout' => 'Vous êtes maintenant déconnecté', 'Link deleted' => 'Lien supprimé', 'Filename' => 'Nom', + 'file' => 'fichier', + 'link' => 'lien', 'Type' => 'Type', 'Size' => 'Taille', 'Expire' => 'Expiration', -- 2.34.1