ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
class.ilAssSingleChoiceFeedback.php
Go to the documentation of this file.
1 <?php
2 /* Copyright (c) 1998-2013 ILIAS open source, Extended GPL, see docs/LICENSE */
3 
4 require_once 'Modules/TestQuestionPool/classes/feedback/class.ilAssConfigurableMultiOptionQuestionFeedback.php';
5 
15 {
19  protected $questionOBJ;
20 
24  const SPECIFIC_QUESTION_TABLE_NAME = 'qpl_qst_sc';
25 
31  protected function getSpecificQuestionTableName()
32  {
33  return self::SPECIFIC_QUESTION_TABLE_NAME;
34  }
35 
41  protected function buildAnswerOptionLabel($index, $answer)
42  {
43  $label = array();
44 
45  if (strlen($answer->getImage())) {
46  if ($this->questionOBJ->getThumbSize()) {
47  $src = $this->questionOBJ->getImagePathWeb() . $this->questionOBJ->getThumbPrefix() . $answer->getImage();
48  } else {
49  $src = $this->questionOBJ->getImagePathWeb() . $answer->getImage();
50  }
51 
52  $label[] = "<img src='{$src}' />";
53  }
54 
55  if (strlen($answer->getAnswertext())) {
56  $label[] = $answer->getAnswertext();
57  }
58 
59  return implode('<br />', $label);
60  }
61 }
getSpecificQuestionTableName()
returns the table name for specific question itself
$index
Definition: metadata.php:60
Create styles array
The data for the language used.
const SPECIFIC_QUESTION_TABLE_NAME
table name for specific feedback