2022-10-15 13:32:57 +00:00
|
|
|
<!doctype html>
|
|
|
|
<html lang="en">
|
|
|
|
<head>
|
|
|
|
<meta charset="utf-8"/>
|
|
|
|
<title>Comments</title>
|
|
|
|
</head>
|
|
|
|
<body>
|
2022-10-15 15:32:35 +00:00
|
|
|
{% if comments_pending %}
|
2022-10-15 13:32:57 +00:00
|
|
|
<div id="comments_pending">
|
|
|
|
{% for comment in comments_pending %}
|
|
|
|
<div class="comment{% if comment.needs_approval %} comment_pending{% endif %}" id="comment-{{ comment.id }}">
|
|
|
|
<span class="comment-author">{{ comment.author }}</span>
|
|
|
|
<span class="comment-date">{{ comment.post_time | date(format="%F %R", locale=config.lang) }}</span>
|
|
|
|
{% if admin and comment.needs_approval %}
|
|
|
|
<a href="?approve={{ comment.id }}">Approve</a>
|
|
|
|
{% endif %}
|
|
|
|
{% if admin %}
|
|
|
|
<a href="?remove={{ comment.id }}">Remove</a>
|
|
|
|
{% endif %}
|
|
|
|
<p class="comment-text">{{ comment.text }}</p>
|
|
|
|
</div>
|
|
|
|
{% endfor %}
|
|
|
|
</div>
|
2022-10-15 15:32:35 +00:00
|
|
|
{% endif %}
|
2022-10-15 13:32:57 +00:00
|
|
|
<div id="comments">
|
|
|
|
{% for comment in comments %}
|
|
|
|
<div class="comment{% if comment.needs_approval %} comment_pending{% endif %}" id="comment-{{ comment.id }}">
|
|
|
|
<span class="comment-author">{{ comment.author }}</span>
|
|
|
|
<span class="comment-date">{{ comment.post_time | date(format="%F %R", locale=config.lang) }}</span>
|
|
|
|
{% if admin and comment.needs_approval %}
|
|
|
|
<a href="?approve={{ comment.id }}">Approve</a>
|
|
|
|
{% endif %}
|
|
|
|
{% if admin %}
|
|
|
|
<a href="?remove={{ comment.id }}">Remove</a>
|
|
|
|
{% endif %}
|
|
|
|
<p class="comment-text">{{ comment.text }}</p>
|
|
|
|
</div>
|
|
|
|
{% endfor %}
|
|
|
|
</div>
|
2022-10-20 18:17:49 +00:00
|
|
|
<form id="new_comment-form" action="#new_comment-form" method="post">
|
|
|
|
{% if new_comment_errors %}
|
|
|
|
<p>Whoops, the following error occurred:</p>
|
|
|
|
<ul id="new_comment-errors" class="errors">
|
|
|
|
{% for error in new_comment_errors %}
|
|
|
|
<li class="error">{{ error | safe }}</li>
|
|
|
|
{% endfor %}
|
|
|
|
</ul>
|
|
|
|
{% endif %}
|
2022-10-15 13:32:57 +00:00
|
|
|
<label for="new_comment-author">Your name:</label>
|
2022-10-20 18:17:49 +00:00
|
|
|
<input type="text" id="new_comment-author" name="author" required maxlenth="{{ config.comment_author_max_len }}"/><br/>
|
2022-10-15 13:32:57 +00:00
|
|
|
<label for="new_comment-email">Your e-mail:</label>
|
2022-10-20 18:17:49 +00:00
|
|
|
<input type="email" id="new_comment-email" name="email" maxlength="{{ config.comment_email_max_len }}"/><br/>
|
2022-10-15 13:32:57 +00:00
|
|
|
<label for="new_comment-text">Your comment:</label><br/>
|
2022-10-20 18:17:49 +00:00
|
|
|
<textarea id="new_comment-text" name="text" maxlength="{{ config.comment_text_max_len }}"></textarea><br/>
|
2022-10-15 13:32:57 +00:00
|
|
|
<button type="submit" name="a" value="new_comment">Post comment</button>
|
|
|
|
</form>
|
|
|
|
</body>
|
|
|
|
</html>
|