Scaffold containerized Django/Wagtail app with core features
This commit is contained in:
33
templates/blog/article_page.html
Normal file
33
templates/blog/article_page.html
Normal file
@@ -0,0 +1,33 @@
|
||||
{% extends 'base.html' %}
|
||||
{% load wagtailcore_tags wagtailimages_tags seo_tags %}
|
||||
{% block title %}{{ page.title }} | No Hype AI{% endblock %}
|
||||
{% block content %}
|
||||
<article>
|
||||
<h1>{{ page.title }}</h1>
|
||||
<p>{{ page.read_time_mins }} min read</p>
|
||||
{% if page.hero_image %}
|
||||
{% image page.hero_image fill-1200x630 %}
|
||||
{% endif %}
|
||||
{{ page.body }}
|
||||
{% article_json_ld page %}
|
||||
</article>
|
||||
<section>
|
||||
<h2>Related</h2>
|
||||
{% for article in related_articles %}
|
||||
<a href="{{ article.url }}">{{ article.title }}</a>
|
||||
{% endfor %}
|
||||
</section>
|
||||
{% if page.comments_enabled %}
|
||||
<section>
|
||||
<form method="post" action="{% url 'comment_post' %}">
|
||||
{% csrf_token %}
|
||||
<input type="hidden" name="article_id" value="{{ page.id }}" />
|
||||
<input type="text" name="author_name" required />
|
||||
<input type="email" name="author_email" required />
|
||||
<textarea name="body" required></textarea>
|
||||
<input type="text" name="honeypot" style="display:none" />
|
||||
<button type="submit">Post comment</button>
|
||||
</form>
|
||||
</section>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user