diff options
Diffstat (limited to 'forum/skins/default/templates/question.html')
-rwxr-xr-x | forum/skins/default/templates/question.html | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/forum/skins/default/templates/question.html b/forum/skins/default/templates/question.html index 23c24113..3df778dc 100755 --- a/forum/skins/default/templates/question.html +++ b/forum/skins/default/templates/question.html @@ -5,6 +5,7 @@ {% load smart_if %}
{% load humanize %}
{% load i18n %}
+{% load cache %}
{% block title %}{% spaceless %}{{ question.get_question_title }}{% endspaceless %}{% endblock %}
{% block forejs %}
<meta name="description" content="{{question.summary}}" />
@@ -164,8 +165,8 @@ {% endjoinitems %}
</div>
<div class="post-update-info-container">
- {% post_contributor_info question "original_author" %}
- {% post_contributor_info question "last_updater" %}
+ {% post_contributor_info question "original_author" %}
+ {% post_contributor_info question "last_updater" %}
</div>
<div class="comments-container" id="comments-container-question-{{question.id}}">
{% for comment in question.get_comments|slice:":5" %}
@@ -313,8 +314,8 @@ {% endjoinitems %}
</div>
<div class="post-update-info-container">
- {% post_contributor_info answer "original_author" %}
- {% post_contributor_info answer "last_updater" %}
+ {% post_contributor_info answer "original_author" %}
+ {% post_contributor_info answer "last_updater" %}
</div>
<div class="comments-container" id="comments-container-answer-{{answer.id}}">
{% for comment in answer.get_comments|slice:":5" %}
@@ -468,6 +469,7 @@ {% endblock %}
{% block sidebar %}
+{% cache 600 questions_tags question.id %}
<div class="boxC">
<p>
{% trans "Question tags" %}:
@@ -489,17 +491,21 @@ {% trans "last updated" %}: <strong title="{{ question.last_activity_at }}">{% diff_date question.last_activity_at %}</strong>
</p>
</div>
-
+{% endcache %}
+{% cache 1800 related_questions question.id %}
<div class="boxC">
<h3 class="subtitle">{% trans "Related questions" %}</h3>
<div class="questions-related">
- {% for question in similar_questions %}
+
+ {% for question in similar_questions.data %}
<p>
<a href="{{ question.get_absolute_url }}">{{ question.get_question_title }}</a>
</p>
{% endfor %}
+
</div>
</div>
+{% endcache %}
{% endblock %}
|