LLMS_Quiz_Attempt_Question::get_correct_answer()
Retrieve answer HTML for the question correct answers
Return Return
(string)
Source Source
File: includes/models/model.llms.quiz.attempt.question.php
public function get_correct_answer() {
$ret = '';
$answers = $this->get_correct_answer_array();
if ( $answers ) {
$ret = '<ul class="llms-quiz-attempt-answers">';
foreach ( $answers as $answer ) {
$ret .= sprintf( '<li class="llms-quiz-attempt-answer">%s</li>', wp_kses_post( $answer ) );
}
$ret .= '</ul>';
}
return apply_filters( 'llms_quiz_attempt_question_get_correct_answer', $ret, $answers, $this->get_question(), $this );
}
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
| Version | Description |
|---|---|
| 3.16.15 | Unknown. |
| 3.16.0 | Introduced. |