Browse files

missing htmlSpecialChars() in INPUT's value

  • Loading branch information...
1 parent 1721518 commit 833b9fd8d50f752e07b978c716fda4efe2558210 skodak committed Oct 2, 2004
Showing with 2 additions and 2 deletions.
  1. +2 −2 mod/quiz/questiontypes/shortanswer/questiontype.php
View
4 mod/quiz/questiontypes/shortanswer/questiontype.php
@@ -99,7 +99,7 @@ function save_question_options($question) {
return true;
}
}
-
+
function print_question_formulation_and_controls($question,
$quiz, $readonly, $answers, $correctanswers, $nameprefix) {
/// This implementation is also used by question type NUMERICAL
@@ -115,7 +115,7 @@ function print_question_formulation_and_controls($question,
$stranswer = get_string("answer", "quiz");
if (isset($question->response[$nameprefix])) {
- $value = ' value="'.$question->response[$nameprefix].'" ';
+ $value = ' value="'.htmlSpecialChars($question->response[$nameprefix]).'" ';
} else {
$value = ' value="" ';
}

0 comments on commit 833b9fd

Please sign in to comment.