[ Index ]

PHP Cross Reference of Unnamed Project

title

Body

[close]

/question/type/multianswer/ -> renderer.php (summary)

Multianswer question renderer classes. Handle shortanswer, numerical and various multichoice subquestions

Copyright: 2010 Pierre Pichet
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 472 lines (18 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 5 classes

qtype_multianswer_renderer:: (4 methods):
  formulation_and_controls()
  subquestion()
  correct_response()
  feedback_popup()

qtype_multianswer_textfield_renderer:: (1 method):
  subquestion()

qtype_multianswer_multichoice_inline_renderer:: (1 method):
  subquestion()

qtype_multianswer_multichoice_vertical_renderer:: (5 methods):
  subquestion()
  choice_wrapper_start()
  choice_wrapper_end()
  all_choices_wrapper_start()
  all_choices_wrapper_end()

qtype_multianswer_multichoice_horizontal_renderer:: (4 methods):
  choice_wrapper_start()
  choice_wrapper_end()
  all_choices_wrapper_start()
  all_choices_wrapper_end()


Class: qtype_multianswer_renderer  - X-Ref

Base class for generating the bits of output common to multianswer
(Cloze) questions.
This render the main question text and transfer to the subquestions
the task of display their input elements and status
feedback, grade, correct answer(s)

formulation_and_controls(question_attempt $qa,question_display_options $options)   X-Ref
No description

subquestion(question_attempt $qa,question_display_options $options, $index, question_graded_automatically $subq)   X-Ref
No description

correct_response(question_attempt $qa)   X-Ref
No description

feedback_popup(question_graded_automatically $subq,$fraction, $feedbacktext, $rightanswer, question_display_options $options)   X-Ref
Render the feedback pop-up contents.

param: question_graded_automatically $subq the subquestion.
param: float $fraction the mark the student got. null if this subq was not answered.
param: string $feedbacktext the feedback text, already processed with format_text etc.
param: string $rightanswer the right answer, already processed with format_text etc.
param: question_display_options $options the display options.
return: string the HTML for the feedback popup.

Class: qtype_multianswer_textfield_renderer  - X-Ref

Subclass for generating the bits of output specific to shortanswer
subquestions.

subquestion(question_attempt $qa, question_display_options $options,$index, question_graded_automatically $subq)   X-Ref
No description

Class: qtype_multianswer_multichoice_inline_renderer  - X-Ref

Render an embedded multiple-choice question that is displayed as a select menu.

subquestion(question_attempt $qa, question_display_options $options,$index, question_graded_automatically $subq)   X-Ref
No description

Class: qtype_multianswer_multichoice_vertical_renderer  - X-Ref

Render an embedded multiple-choice question vertically, like for a normal
multiple-choice question.

subquestion(question_attempt $qa, question_display_options $options,$index, question_graded_automatically $subq)   X-Ref
No description

choice_wrapper_start($class)   X-Ref

param: string $class class attribute value.
return: string HTML to go before each choice.

choice_wrapper_end()   X-Ref

return: string HTML to go after each choice.

all_choices_wrapper_start()   X-Ref

return: string HTML to go before all the choices.

all_choices_wrapper_end()   X-Ref

return: string HTML to go after all the choices.

Class: qtype_multianswer_multichoice_horizontal_renderer  - X-Ref

Render an embedded multiple-choice question vertically, like for a normal
multiple-choice question.

choice_wrapper_start($class)   X-Ref
No description

choice_wrapper_end()   X-Ref
No description

all_choices_wrapper_start()   X-Ref
No description

all_choices_wrapper_end()   X-Ref
No description



Generated: Thu Aug 11 10:00:09 2016 Cross-referenced by PHPXref 0.7.1