Update of 
/var/cvs/contributions/didactor2/src/education/templates/education/mcquestions
In directory james.mmbase.org:/tmp/cvs-serv18568

Modified Files:
        index.jsp ratemcquestions.jsp 
Log Message:



See also: 
http://cvs.mmbase.org/viewcvs/contributions/didactor2/src/education/templates/education/mcquestions


Index: index.jsp
===================================================================
RCS file: 
/var/cvs/contributions/didactor2/src/education/templates/education/mcquestions/index.jsp,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -b -r1.15 -r1.16
--- index.jsp   20 Nov 2008 15:10:43 -0000      1.15
+++ index.jsp   20 Nov 2008 17:45:01 -0000      1.16
@@ -63,8 +63,9 @@
                     <mm:field name="description" escape="tagstripper(xss)"/>
                   </mm:relatednodes>
                 </div>
-                <mm:import externid="${question}" id="answer" />
-                <mm:radio type="checkbox" name="${question}_${_node}"  
value="${_node}" checked="${mm:contains(givenanswers, _node)}" />
+                <mm:import externid="${question}" 
id="answer">${givenanswers}</mm:import>
+                <mm:radio type="radio" name="${question}"  value="${_node}" 
compare="${answer}"  />
+
                 <mm:field name="text" />
 
                 <!-- Each answer on a new line -->


Index: ratemcquestions.jsp
===================================================================
RCS file: 
/var/cvs/contributions/didactor2/src/education/templates/education/mcquestions/ratemcquestions.jsp,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -b -r1.16 -r1.17
--- ratemcquestions.jsp 20 Nov 2008 15:10:43 -0000      1.16
+++ ratemcquestions.jsp 20 Nov 2008 17:45:01 -0000      1.17
@@ -4,6 +4,7 @@
     xmlns:c="http://java.sun.com/jsp/jstl/core";
     xmlns:di="http://www.didactor.nl/ditaglib_1.0"; >
   <mm:content
+      expires="0"
       postprocessor="reducespace">
 
     <mm:cloud method="delegate">
@@ -49,7 +50,9 @@
           <c:when test="${_ eq 0}">
             <!-- Only 1 answer is given -->
 
-            <mm:import externid="$question" id="givenanswer" />
+            <mm:import externid="${question}" id="givenanswer" />
+
+
             <mm:present referid="givenanswer">
               <mm:node referid="givenanswer">
                 <mm:field id="questioncorrect" name="correct" write="false"/>
@@ -72,18 +75,15 @@
 
               <mm:import externid="${question}_${_node}" id="givenanswer" />
 .
-              <mm:log>Value for givenanser (${question}_${_node}): 
${givenanswer}</mm:log>
               <mm:present referid="givenanswer">
                 <!-- Relate each given answer to the possible answers -->
                 <mm:createrelation id="r" role="related" 
source="my_givenanswers" destination="my_answers"/>
-                <mm:log> <mm:node referid="r"><mm:nodeinfo type="gui" 
/></mm:node></mm:log>
                 <!-- when this is a false answer, the score is incorrect -->
                 <mm:compare referid="correct" value="0">
                   <mm:remove referid="score"/><mm:import 
id="score">0</mm:import>
                 </mm:compare>
               </mm:present>
               <mm:notpresent referid="givenanswer">
-                <mm:log>this answer was not given</mm:log>
                 <!-- when the student had to check the button of thge correct 
answer, the score is incorrect -->
                 <mm:compare referid="correct" value="1">
                   <mm:remove referid="score"/>
_______________________________________________
Cvs mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/cvs

Reply via email to