]> git.mjollnir.org Git - moodle.git/commitdiff
merged choice fix from Stable MDL-7171
authordanmarsden <danmarsden>
Tue, 31 Oct 2006 19:00:55 +0000 (19:00 +0000)
committerdanmarsden <danmarsden>
Tue, 31 Oct 2006 19:00:55 +0000 (19:00 +0000)
mod/choice/view.php

index 54605de82fcf185635c5cb4ba2f4ed1ff5dc7d17..265d64aa3e49a8a7e4f570e88fd15e7f4ec06172 100644 (file)
 
 
 
-    // print the results at the bottom of the screen
-
-    if ( $choice->showresults == CHOICE_SHOWRESULTS_ALWAYS or
-        ($choice->showresults == CHOICE_SHOWRESULTS_AFTER_ANSWER and $current ) or
-        ($choice->showresults == CHOICE_SHOWRESULTS_AFTER_CLOSE and $choice->timeclose <= time() ) )  {
-
-        choice_show_results($choice, $course, $cm);
-
-    } else if (!$choiceformshown) {
-        print_simple_box(get_string('noresultsviewable', 'choice'), 'center');
-    } 
-    
     if (!$choiceformshown) {
 
         $sitecontext = get_context_instance(CONTEXT_SYSTEM);
         }
     }
 
+    // print the results at the bottom of the screen
+
+    if ( $choice->showresults == CHOICE_SHOWRESULTS_ALWAYS or
+        ($choice->showresults == CHOICE_SHOWRESULTS_AFTER_ANSWER and $current ) or
+        ($choice->showresults == CHOICE_SHOWRESULTS_AFTER_CLOSE and $choice->timeclose <= time() ) )  {
+
+        choice_show_results($choice, $course, $cm);
+
+    } else if (!$choiceformshown) {
+        print_simple_box(get_string('noresultsviewable', 'choice'), 'center');
+    } 
+
+
     print_footer($course);