diff --git a/main/exercise/UniqueAnswerImage.php b/main/exercise/UniqueAnswerImage.php index 333be370c3..918ee089b6 100644 --- a/main/exercise/UniqueAnswerImage.php +++ b/main/exercise/UniqueAnswerImage.php @@ -348,7 +348,8 @@ class UniqueAnswerImage extends UniqueAnswer public function return_header(Exercise $exercise, $counter = null, $score = []) { if ($exercise->showExpectedChoice()) { - $header = ' + $header = parent::return_header($exercise, $counter, $score, false); + $header .= '
'; if ($exercise->showExpectedChoiceColumn()) { diff --git a/main/exercise/unique_answer.class.php b/main/exercise/unique_answer.class.php index 6d633bb3dd..12a1727efc 100755 --- a/main/exercise/unique_answer.class.php +++ b/main/exercise/unique_answer.class.php @@ -429,23 +429,24 @@ class UniqueAnswer extends Question /** * {@inheritdoc} */ - public function return_header(Exercise $exercise, $counter = null, $score = []) + public function return_header(Exercise $exercise, $counter = null, $score = [], $displayTableHead = true) { $header = parent::return_header($exercise, $counter, $score); - $header .= '
'.get_lang('Choice').'
'; + if ($displayTableHead) { + $header .= '
'; - $header .= ''; - if ($exercise->showExpectedChoiceColumn()) { - $header .= ''; - } + $header .= ''; + if ($exercise->showExpectedChoiceColumn()) { + $header .= ''; + } - $header .= ''; - if ($exercise->showExpectedChoice()) { - $header .= ''; + $header .= ''; + if ($exercise->showExpectedChoice()) { + $header .= ''; + } + $header .= ''; + $header .= ''; } - $header .= ''; - $header .= ''; - return $header; }
'.get_lang('Choice').''.get_lang('ExpectedChoice').''.get_lang('Choice').''.get_lang('ExpectedChoice').''.get_lang('Answer').''.get_lang('Status').''.get_lang('Answer').''.get_lang('Status').''.get_lang('Comment').'
'.get_lang('Comment').'