]> git.mjollnir.org Git - moodle.git/commitdiff
Fixed Bug 1132.
authorrkingdon <rkingdon>
Fri, 12 Mar 2004 15:32:41 +0000 (15:32 +0000)
committerrkingdon <rkingdon>
Fri, 12 Mar 2004 15:32:41 +0000 (15:32 +0000)
mod/lesson/lesson.php
mod/lesson/view.php

index 89ceee05a1953a79dcd4b0e612cd8a8f14be8719..2d644a1db698b960d56d868eb4a256997415bf8e 100644 (file)
@@ -50,7 +50,7 @@
        // ... print the header and...
     print_header("$course->shortname: $lesson->name", "$course->fullname",
                  "$navigation <A HREF=index.php?id=$course->id>$strlessons</A> -> 
-                  <A HREF=\"view.php?id=$cm->id\">$lesson->name</A> -> $action", 
+                  <A HREF=\"view.php?id=$cm->id\">$lesson->name</A>", 
                   "", "", true);
 
        //...get the action 
         echo "<tr><td><b>".get_string("questiontype", "lesson").":</b> \n";
         choose_from_menu($LESSON_QUESTION_TYPE, "qtype", LESSON_MULTICHOICE, "");
         helpbutton("questiontype", get_string("questiontype", "lesson"), "lesson");
-        echo "<br /><input type=\"checkbox\" name=\"qoption\" value=\"1\"/>";
-        echo " <b>".get_string("questionoption", "lesson")."</b>\n";
+        echo "<br /><b>".get_string("questionoption", "lesson").":</b>\n";
+        echo " <input type=\"checkbox\" name=\"qoption\" value=\"1\"/>";
         helpbutton("questionoption", get_string("questionoption", "lesson"), "lesson");
         echo "</td></tr>\n";
         for ($i = 0; $i < $lesson->maxanswers; $i++) {
                 } else {
                     echo "<input type=\"checkbox\" name=\"qoption\" value=\"1\"/>";
                 }
-                echo " <b>".get_string("morethanoneanswer", "lesson")."</b>\n";
+                echo " <b>".get_string("multianswer", "lesson")."</b>\n";
                 break;
         }       
         helpbutton("questiontypes", get_string("questiontype", "lesson"), "lesson");
                     }
                 } else {
                     // it's a new answer
+                    unset($newanswer); // need to clear id if more than one new answer is ben added
                     $newanswer->lessonid = $lesson->id;
                     $newanswer->pageid = $page->id;
                     $newanswer->timecreated = $timenow;
index 426084f3fe1337a0d79b102ba7df1ce93459b6b5..5972977cc0a51541264e5046e8d0fef948b38e51 100644 (file)
             echo get_string("pagecontents", "lesson").":</b><br />\n";
             print_textarea($usehtmleditor, 25, 70, 630, 400, "contents");
             echo "</td></tr>\n";
+            echo "<tr><td><b>".get_string("questiontype", "lesson").":</b> \n";
+            choose_from_menu($LESSON_QUESTION_TYPE, "qtype", LESSON_MULTICHOICE, "");
+            helpbutton("questiontype", get_string("questiontype", "lesson"), "lesson");
+            echo "<br /><b>".get_string("questionoption", "lesson").":</b>\n";
+            echo " <input type=\"checkbox\" name=\"qoption\" value=\"1\"/>";
+            helpbutton("questionoption", get_string("questionoption", "lesson"), "lesson");
+            echo "</td></tr>\n";
             for ($i = 0; $i < $lesson->maxanswers; $i++) {
                 $iplus1 = $i + 1;
                 echo "<tr><td><b>".get_string("answer", "lesson")." $iplus1:</b><br />\n";
                                     break;
                                 case LESSON_MULTICHOICE :
                                     if ($page->qoption) {
-                                        echo " - ".get_string("morethanoneanswer", "lesson");
+                                        echo " - ".get_string("multianswer", "lesson");
                                     }
                                     break;
                                 case LESSON_MATCHING :