Exemple #1
0
 public function manual_comment_view(question_attempt $qa, question_display_options $options)
 {
     $output = '';
     if ($qa->has_manual_comment()) {
         $output .= get_string('commentx', 'question', $qa->get_behaviour()->format_comment());
     }
     if ($options->manualcommentlink) {
         $url = new moodle_url($options->manualcommentlink, array('slot' => $qa->get_slot()));
         $link = $this->output->action_link($url, get_string('commentormark', 'question'), new popup_action('click', $url, 'commentquestion', array('width' => 600, 'height' => 800)));
         $output .= html_writer::tag('div', $link, array('class' => 'commentlink'));
     }
     return $output;
 }