Code Duplication    Length = 7-8 lines in 3 locations

install/actions/action_summary.php 2 locations

@@ 238-244 (lines=7) @@
235
// check table prefix
236
if ($conn && $installMode == 0) {
237
    echo '<p>' . $_lang['checking_table_prefix'] . $table_prefix . '`: ';
238
    if ($rs= mysqli_query($conn, "SELECT COUNT(*) FROM $dbase.`" . $table_prefix . "site_content`")) {
239
        echo '<span class="notok">' . $_lang['failed'] . '</span></b>' . $_lang['table_prefix_already_inuse'] . '</p>';
240
        $errors++;
241
        echo "<p>" . $_lang['table_prefix_already_inuse_note'] . '</p>';
242
    } else {
243
        echo '<span class="ok">' . $_lang['ok'] . '</span></p>';
244
    }
245
} elseif ($conn && $installMode == 2) {
246
    echo '<p>' . $_lang['checking_table_prefix'] . $table_prefix . '`: ';
247
    if (!$rs = mysqli_query($conn, "SELECT COUNT(*) FROM $dbase.`" . $table_prefix . "site_content`")) {
@@ 247-253 (lines=7) @@
244
    }
245
} elseif ($conn && $installMode == 2) {
246
    echo '<p>' . $_lang['checking_table_prefix'] . $table_prefix . '`: ';
247
    if (!$rs = mysqli_query($conn, "SELECT COUNT(*) FROM $dbase.`" . $table_prefix . "site_content`")) {
248
        echo '<span class="notok">' . $_lang['failed'] . '</span></b>' . $_lang['table_prefix_not_exist'] . '</p>';
249
        $errors++;
250
        echo '<p>' . $_lang['table_prefix_not_exist_note'] . '</p>';
251
  } else {
252
        echo '<span class="ok">' . $_lang['ok'] . '</span></p>';
253
  }
254
}
255
256
// check mysql version

install/instprocessor.php 1 location

@@ 117-124 (lines=8) @@
114
// check table prefix
115
if ($installMode == 0) {
116
    echo "<p>" . $_lang['checking_table_prefix'] . $table_prefix . "`: ";
117
    if (@ $rs = mysqli_query($conn, "SELECT COUNT(*) FROM $dbase.`" . $table_prefix . "site_content`")) {
118
        echo '<span class="notok">' . $_lang['failed'] . "</span>" . $_lang['table_prefix_already_inuse'] . "</p>";
119
        $errors += 1;
120
        echo "<p>" . $_lang['table_prefix_already_inuse_note'] . "</p>";
121
        return;
122
    } else {
123
        echo '<span class="ok">'.$_lang['ok']."</span></p>";
124
    }
125
}
126
127
if(!function_exists('parseProperties')) {