##// END OF EJS Templates
Updated the Snow White theme. Scroll to the new post after posting to thread.
Updated the Snow White theme. Scroll to the new post after posting to thread.

File last commit:

r39:e544cbe2 default
r41:68192446 default
Show More
posting_general.html
83 lines | 3.0 KiB | text/html | HtmlLexer
{% extends "base.html" %}
{% load i18n %}
{% load markup %}
{% block head %}
<title>Neboard</title>
{% endblock %}
{% block content %}
{% if threads %}
{% for thread in threads %}
<div class="post">
{% if thread.image %}
<div class="image">
<a href="{{ thread.image.url }}"><img
src="{{ thread.image.url_200x150 }}" />
</a>
</div>
{% endif %}
<div class="message">
<span class="title">{{ thread.title }}</span>
<span class="post_id">(#{{ thread.id }})</span>
[{{ thread.pub_time }}]
[<a class="link" href="{% url 'thread' thread.id %}"
>{% trans "View" %}</a>]
{% autoescape off %}
{{ thread.text.rendered|truncatechars:300 }}
{% endautoescape %}
</div>
<div class="metadata">
{{ thread.get_reply_count }} {% trans 'replies' %},
{{ thread.get_images_count }} {% trans 'images' %},
{{ thread.get_gets_count }} {% trans 'gets' %}.
{% if thread.tags.all %}
<span class="tags">{% trans 'Tags' %}:
{% for tag in thread.tags.all %}
<a class="tag" href="
{% url 'tag' tag_name=tag.name %}">
{{ tag.name }}</a>
{% endfor %}
</span>
{% endif %}
</div>
</div>
{% endfor %}
{% else %}
No threads found.
<hr />
{% endif %}
<form enctype="multipart/form-data" method="post">{% csrf_token %}
<div class="post-form-w">
<div class="form-title">{% trans "Create new thread" %}</div>
<div class="post-form">
<div class="form-row">
<div class="form-label">{% trans 'Title' %}</div>
<div class="form-input">{{ form.title }}</div>
</div>
<div class="form-row">
<div class="form-label">{% trans 'Text' %}</div>
<div class="form-input">{{ form.text }}</div>
</div>
<div class="form-row">
<div class="form-label">{% trans 'Image' %}</div>
<div class="form-input">{{ form.image }}</div>
</div>
<div class="form-row">
<div class="form-label">{% trans 'Tags' %}</div>
<div class="form-input">{{ form.tags }}</div>
</div>
</div>
<div class="form-submit"><input type="submit"
value="{% trans "Post" %}"/></div>
<div>Tags must be delimited by spaces. Text or image is required
</div>
<div>Use <a
href="http://daringfireball.net/projects/markdown/basics">
markdown</a> syntax for posting.</div>
</div>
</form>
{% endblock %}