From 75160b12821f7f4299cce7f0b69c83c1502ae071 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anton=20Luka=20=C5=A0ijanec?= Date: Mon, 27 May 2024 13:08:29 +0200 Subject: 2024-02-19 upstream --- admin/survey/parapodatki.php | 28 ++++++++++++++++++++++++---- 1 file changed, 24 insertions(+), 4 deletions(-) (limited to 'admin/survey/parapodatki.php') diff --git a/admin/survey/parapodatki.php b/admin/survey/parapodatki.php index b1615cd..95be083 100644 --- a/admin/survey/parapodatki.php +++ b/admin/survey/parapodatki.php @@ -106,9 +106,7 @@ if ($_GET['a'] == 'ankete') { if (mysqli_num_rows($sql) > 0) { $row = mysqli_fetch_array($sql); - - if ($row['db_table'] == 1) $db_table = '_active'; else $db_table = ''; - + echo $row['id'].delimiter; echo $row['insert_uid'].delimiter; echo $row['a_first'].delimiter; @@ -232,7 +230,29 @@ if ($_GET['a'] == 'ankete') { while ($row = mysqli_fetch_array($sql)) { - if ($row['db_table'] == 1) $db_table = '_active'; else $db_table = ''; + switch($row['db_table']){ + + // Arhivska 1 + case '0': + $db_table = '_archive1'; + break; + + // Arhivska 2 + case '2': + $db_table = '_archive2'; + break; + + // Arhivska 3 + case '3': + $db_table = '_archive3'; + break; + + // Aktivna anketa + case '1': + default: + $db_table = '_active'; + break; + } echo $row['id'].delimiter; echo $row['uid'].delimiter; -- cgit v1.2.3