summaryrefslogtreecommitdiffhomepage
path: root/apioforum/templates
diff options
context:
space:
mode:
Diffstat (limited to 'apioforum/templates')
-rw-r--r--apioforum/templates/common.html2
-rw-r--r--apioforum/templates/search_results.html18
2 files changed, 19 insertions, 1 deletions
diff --git a/apioforum/templates/common.html b/apioforum/templates/common.html
index 2206ac3..fc41410 100644
--- a/apioforum/templates/common.html
+++ b/apioforum/templates/common.html
@@ -14,7 +14,7 @@
<a class="actionbutton"
href="{{url_for('thread.delete_post',post_id=post.id)}}">delete</a>
{% endif %}
- <a class="post-anchor-link" href="#post_{{post.id}}">#{{post.id}}</a>
+ <a class="post-anchor-link" href="{{url_for('thread.view_thread', thread_id=post.thread)}}}#post_{{post.id}}">#{{post.id}}</a>
</span>
</div>
<div class="post-content">
diff --git a/apioforum/templates/search_results.html b/apioforum/templates/search_results.html
new file mode 100644
index 0000000..7035e8f
--- /dev/null
+++ b/apioforum/templates/search_results.html
@@ -0,0 +1,18 @@
+{% from 'common.html' import disp_post %}
+{% extends 'base.html' %}
+{% block header %}
+<h1>{%block title %}Results for {{query}}{% endblock %}</h1>
+{% endblock %}
+
+{%block content%}
+<div class="results">
+ {% for result in results %}
+ {% if display_thread_id[loop.index0] %}
+ <h3><a href="{{url_for('thread.view_thread', thread_id=result.thread)}}">{{ result.thread_title }}</a></h3>
+ {% endif %}
+ {% call disp_post(result, True) %}
+ {{ rendered_posts[loop.index0] | safe}}
+ {% endcall %}
+ {% endfor %}
+</div>
+{% endblock %}