footer added
[koed-quiz.git] / apps / quiz / templates / quiz / question_detail.html
index b739a98..c219434 100755 (executable)
@@ -1,36 +1,43 @@
-{% extends "base.html" %}
+{% extends "quiz/base.html" %}
 {% load i18n %}
 {% load url from future %}
 
+
+{% block "title" %}{{ question.quiz.name }}{% endblock %}
+{% block "header" %}{{ question.quiz.name }}{% endblock %}
+
+
 {% block "body" %}
 
 
-<h1>{{ question.title }}</h1>
-<div>
-{{ question.text }}
-</div>
+<h2>{{ question.title }}</h2>
+{% if question.text %}
+    <div>
+    {{ question.text|safe }}
+    </div>
+{% endif %}
 
 <div>
 
 
 
-<form method='post'>
+<form class='question' method='post'>
 {% csrf_token %}
 {{ form.answer.errors }}
 {{ form.answer }}
 
 {% if valid %}
-    <input type='submit' />
+    <button>{% trans "Send answer" %}</button>
 
     {% if previous_url %}
-        <a href='{{ previous_url }}'>{% trans "Back to last question" %}</a>
+        <a class='button' href='{{ previous_url }}'>{% trans "Back to last question" %}</a>
     {% endif %}
 
 {% else %}
     {% if valid_url %}
-        <a href='{{ valid_url }}'>{% trans "Back to my test" %}</a>
+        <a class='button' href='{{ valid_url }}'>{% trans "Back to my test" %}</a>
     {% else %}
-        <a href='{% url "quiz" %}'>{% trans "Start from the beginning" %}</a>
+        <a class='button' href='{% url "quiz" %}'>{% trans "Start from the beginning" %}</a>
     {% endif %}
 {% endif %}
 
 </div>
 
 
-<div>
-{{ question.description }}
-</div>
+{% if question.description %}
+    <div id='description'>
+    {{ question.description|safe }}
+    </div>
+{% endif %}
 
 
 {% endblock %}