Code Duplication    Length = 9-16 lines in 3 locations

main/exercise/calculated_answer.class.php 1 location

@@ 249-257 (lines=9) @@
246
     * @param null $score
247
     * @return null|string
248
     */
249
    public function return_header($feedback_type = null, $counter = null, $score = null)
250
    {
251
        $header = parent::return_header($feedback_type, $counter, $score);
252
        $header .= '<table class="'.$this->question_table_class .'">
253
            <tr>
254
                <th>'.get_lang("Answer").'</th>
255
            </tr>';
256
        return $header;
257
    }
258
259
    /**
260
     * Returns true if the current question has been attempted to be answered

main/exercise/fill_blanks.class.php 1 location

@@ 418-427 (lines=10) @@
415
     * @param null $score
416
     * @return string
417
     */
418
    public function return_header($feedback_type = null, $counter = null, $score = null)
419
    {
420
        $header = parent::return_header($feedback_type, $counter, $score);
421
        $header .= '<table class="'.$this->question_table_class .'">
422
            <tr>
423
                <th>'.get_lang("Answer").'</th>
424
            </tr>';
425
426
        return $header;
427
    }
428
429
    /**
430
     * @param string $separatorStartRegexp

main/exercise/oral_expression.class.php 1 location

@@ 70-85 (lines=16) @@
67
     * @param null $score
68
     * @return null|string
69
     */
70
    function return_header($feedback_type = null, $counter = null, $score = null)
71
    {
72
        $header = parent::return_header($feedback_type, $counter, $score);
73
        $header .= '<table class="'.$this->question_table_class.'">
74
            <tr>
75
                <th>&nbsp;</th>
76
            </tr>
77
            <tr>
78
                <th>'.get_lang("Answer").'</th>
79
            </tr>
80
            <tr>
81
                <th>&nbsp;</th>
82
            </tr>';
83
84
        return $header;
85
    }
86
87
    /**
88
     * initialize the attributes to generate the file path