diff options
author | prathamesh | 2014-06-27 17:20:02 +0530 |
---|---|---|
committer | prathamesh | 2014-06-27 17:20:02 +0530 |
commit | faacb5ba720abc9660e1afa12c9a3c4d0761254f (patch) | |
tree | e4ebc764981e3e223242b9e60611f03c3de51a3f /testapp/templates | |
parent | b61c62291424089478064af1fceb81c1ed4e5c54 (diff) | |
download | online_test-faacb5ba720abc9660e1afa12c9a3c4d0761254f.tar.gz online_test-faacb5ba720abc9660e1afa12c9a3c4d0761254f.tar.bz2 online_test-faacb5ba720abc9660e1afa12c9a3c4d0761254f.zip |
Mutiple correct choices question type added.
Diffstat (limited to 'testapp/templates')
-rw-r--r-- | testapp/templates/exam/question.html | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/testapp/templates/exam/question.html b/testapp/templates/exam/question.html index c8454ff..a3e8629 100644 --- a/testapp/templates/exam/question.html +++ b/testapp/templates/exam/question.html @@ -106,7 +106,14 @@ function setSnippetHeight() {% for option in question.options.strip.splitlines %} <input name="answer" type="radio" value="{{option}}" />{{option}} <br/> {% endfor %} - {% else %} + {% endif %} + {% if question.type == "mcc" %} + {% for option in question.options.strip.splitlines %} + <input name="answer" type="checkbox" value="{{ option }}"> {{ option }} + <br> + {% endfor %} + {% endif %} + {% if question.type == "code" %} <textarea rows="1" style="padding:0;height:auto;width:750px;overflow:hidden;background-color:white;border: 0 none white;" readonly="yes" name="snippet" id="snippet" wrap="off">{% if last_attempt %}{{ question.snippet }}{% else %}{% if question.type == "bash" %} #!/bin/bash {{ question.snippet }}{% else %}{{ question.snippet }}{% endif %}{% endif %}</textarea> @@ -119,7 +126,7 @@ function setSnippetHeight() <script>addLineNumbers('snippet');</script> {% endif %} - {% if question.type == "mcq" %} + {% if question.type == "mcq" or question.type == "mcc "%} <br><button class="btn" type="submit" name="check" id="check">Submit Answer</button> {% else %} <button class="btn" type="submit" name="check" id="check" onClick="submitCode();">Check Answer</button> |