From: moodler Date: Wed, 21 May 2003 05:00:44 +0000 (+0000) Subject: Change to parsing to allow answers in any order - needs testing X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=79da6d8717c3fb396be4d8b35a76d0efd120e6af;p=moodle.git Change to parsing to allow answers in any order - needs testing --- diff --git a/mod/quiz/format/missingword.php b/mod/quiz/format/missingword.php index a7a7868460..bf8f03c6ab 100644 --- a/mod/quiz/format/missingword.php +++ b/mod/quiz/format/missingword.php @@ -55,7 +55,11 @@ class quiz_file_format extends quiz_default_format { /// Parse the answers + $answers = str_replace("=", "~=", $answertext); $answers = explode("~", $answertext); + if (empty(trim($answers[0]))) { + array_shift($answers); + } $countanswers = count($answers);