Definition at line 347 of file question_renderer.inc.
◆ drawGraph()
SelectFieldView::drawGraph |
( |
|
$mgr, |
|
|
|
$answers |
|
) |
| |
Draws an interactive graphical view of answers to one question.
- Parameters
-
obj | $mgr | - object of the Survey/Questionnaire Results manager class |
Array | $answers | - all survey or questionnaire answers to this question |
Definition at line 405 of file question_renderer.inc.
static drawSelectGraph($question, $resultsManager, $answers)
Draws an interactive graphical view of answers to one question.
◆ drawView()
SelectFieldView::drawView |
( |
| ) |
|
◆ getAnswer()
SelectFieldView::getAnswer |
( |
| ) |
|
◆ SelectFieldView()
SelectFieldView::SelectFieldView |
( |
|
$parent, |
|
|
|
$question |
|
) |
| |
Definition at line 349 of file question_renderer.inc.
QuestionField($parent, $question)
$question
The question renderer obj.
$parent
The parent QuestionForm obj.
◆ writeHTML()
SelectFieldView::writeHTML |
( |
| ) |
|
Reimplemented from QuestionField.
Definition at line 355 of file question_renderer.inc.
357 $options = explode(
"\n", $this->question->options);
360 $value = $this->parent->getAnswer($this->question);
362 $readonly = $this->parent->readOnlyForm ?
" DISABLED" :
"";
366 echo
"<table class=\"layout\">";
367 $pk = $this->question->getPrimaryKey();
368 echo
"<select name='question_{$this->question->$pk}'>\n";
371 echo
"<option value=''></option>";
376 $selected = ($value == $num) ?
" selected" :
"";
377 echo
"<option value='$num'$readonly$selected>$option</option>";
$readonly
Whether the questions should be drawn readonly.
The documentation for this class was generated from the following file: