From 323a0d7d0d65d6afc5ae996bd8e24f0e5f867cb2 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 2 Nov 2017 15:48:24 +0100 Subject: [PATCH] Update index.php --- htdocs/comm/action/index.php | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/htdocs/comm/action/index.php b/htdocs/comm/action/index.php index ea6c43b89c7..87f0e2e6ccb 100644 --- a/htdocs/comm/action/index.php +++ b/htdocs/comm/action/index.php @@ -486,8 +486,14 @@ if (! empty($actioncode)) elseif ($actioncode == 'AC_ALL_AUTO') $sql.= " AND ca.type = 'systemauto'"; else { - $TActionCode=(Array)$actioncode; - $sql.=" AND ca.code IN ('".implode("','", $TActionCode)."')"; + if (is_array($actioncode)) + { + $sql.=" AND ca.code IN ('".implode("','", $TActionCode)."')"; + } + else + { + $sql.=" AND ca.code IN ('".implode("','", explode(',', $actioncode))."')"; + } } } }