Code Duplication    Length = 5-5 lines in 3 locations

admin/donations.php 3 locations

@@ 533-537 (lines=5) @@
530
    $ordinaux   = explode('|', _AD_DON_NUMBER_ORDINAUX);
531
    //-------------------------------------------------------------
532
    $h = 0;
533
    do {
534
        $ord = $ordinaux[$h++];
535
        $row1 .= "    <td title=\"{$desc}\" style=\"text-align: center;\">{$ord}</td>\n";
536
        $row2 .= "    <td title=\"{$desc}\" style=\"text-align: center;\"><input size=\"4\" name=\"var_week_goal-$row_Recordset1[subtype]\" type=\"text\" value=\"$row_Recordset1[value]\" onChange=\"return validInt(this,'$row_Recordset1[subtype] " . _AD_DON_GOAL_DONATION . "',1,'" . _AD_DON_ALERTE_INPUT_NUMBER . "');\" /></td>\n";
537
    } while (false != ($row_Recordset1 = $xoopsDB->fetchArray($Recordset1)));
538
    $row1 .= "  </tr>\n";
539
    $row2 .= "  </tr>\n";
540
    echo "{$row1} {$row2}";
@@ 555-559 (lines=5) @@
552
    echo "  <tr><td style=\"text-align: center; width: 100%; font-weight: bold;\" colspan=\"13\">" . _AD_DON_GOAL_MENSUEL . "</td></tr><br />\n";
553
    $row1 = "  <tr>\n" . "    <td style=\"text-align: center; font-weight: bold;\">" . _AD_DON_MONTH . "</td>\n";
554
    $row2 = "  <tr>\n" . "    <td style=\"text-align: center; font-weight: bold;\">" . _AD_DON_GOAL . "</td>\n";
555
    do {
556
        $month = $shortMonth[$h++];
557
        $row1 .= "    <td title=\"{$desc}\" style=\"text-align: center;\">{$month}</td>\n";
558
        $row2 .= "    <td title=\"{$desc}\" style=\"text-align: center;\"><input size=\"4\" name=\"var_month_goal-$row_Recordset1[subtype]\" type=\"text\" value=\"$row_Recordset1[value]\" onChange=\"return validInt(this,'$row_Recordset1[subtype] " . _AD_DON_GOAL_DONATION . "',1,'" . _AD_DON_ALERTE_INPUT_NUMBER . "');\" /></td>\n";
559
    } while (false != ($row_Recordset1 = $xoopsDB->fetchArray($Recordset1)));
560
    $row1 .= "  </tr>\n";
561
    $row2 .= "  </tr>\n";
562
    echo "{$row1}{$row2}";
@@ 580-584 (lines=5) @@
577
    $row1 = "  <tr><td style=\"text-align: center; font-weight: bold;\">" . _AD_DON_QUARTER . "</td>\n";
578
    $row2 = "  <tr><td style=\"text-align: center; font-weight: bold;\">" . _AD_DON_GOAL . "</td>\n";
579
    $h    = 0;
580
    do {
581
        $ord = $ordinaux[$h++];
582
        $row1 .= "    <td title='{$desc}' style='text-align: center;'>{$ord}</td>\n";
583
        $row2 .= "    <td title='{$desc}' style='text-align: center;'><input size=\"4\" name=\"var_quarter_goal-$row_Recordset1[subtype]\" type=\"text\" value=\"$row_Recordset1[value]\" onChange=\"return validInt(this,'$row_Recordset1[subtype] " . _AD_DON_GOAL_DONATION . "',1,'" . _AD_DON_ALERTE_INPUT_NUMBER . "');\" /></td>\n";
584
    } while (false != ($row_Recordset1 = $xoopsDB->fetchArray($Recordset1)));
585
    $row1 .= "  </tr>\n";
586
    $row2 .= "  </tr>\n";
587
    echo "{$row1} {$row2}";