From ad9a1b9e2132a7f91026989ab33c571bfb230076 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9Cankush=5Fm=E2=80=9D?= Date: Mon, 23 Dec 2019 15:17:12 +0530 Subject: [PATCH] Task #154510 feat: Import Records from the frontend --- src/components/com_tjucm/site/controllers/items.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/com_tjucm/site/controllers/items.php b/src/components/com_tjucm/site/controllers/items.php index 647eeeed..9b264ceb 100644 --- a/src/components/com_tjucm/site/controllers/items.php +++ b/src/components/com_tjucm/site/controllers/items.php @@ -68,7 +68,7 @@ public function importCsv() } // Check if the file is a CSV file - if ($importFile['type'] != "text/csv") + if (!in_array($importFile['type'], array('application/vnd.ms-excel', 'text/plain', 'text/csv', 'text/tsv'))) { $app->enqueueMessage(Text::_('COM_TJUCM_ITEMS_INVALID_CSV_FILE'), 'error'); $app->redirect(Uri::root() . 'index.php?option=com_tjucm&view=items&layout=importitems&tmpl=component&client=' . $client);