Пример #1
0
 /**
  * Implementation of getNodeView
  *
  * @see QuizQuestion#getNodeView()
  */
 public function getNodeView()
 {
     $content = parent::getNodeView();
     if ($this->viewCanRevealCorrect()) {
         $content['answers'] = array('#type' => 'item', '#title' => t('Rubric'), '#markup' => '<div class="quiz-solution">' . check_markup($this->node->rubric, $this->getFormat()) . '</div>', '#weight' => 1);
     } else {
         $content['answers'] = array('#markup' => '<div class="quiz-answer-hidden">Answer hidden</div>', '#weight' => 1);
     }
     return $content;
 }