Tags 在POST或/tag页下未显示摇摆标签
我正在遵循此指南> 据我所知,我完全按照指南中的内容进行了操作,但是在查看单个博客文章时,标签不会加载,而且标签页面也不会显示标签列表。我没有收到任何错误,只是没有出现 当通过链接进行搜索时会显示它们,例如Tags 在POST或/tag页下未显示摇摆标签,tags,wagtail,Tags,Wagtail,我正在遵循此指南> 据我所知,我完全按照指南中的内容进行了操作,但是在查看单个博客文章时,标签不会加载,而且标签页面也不会显示标签列表。我没有收到任何错误,只是没有出现 当通过链接进行搜索时会显示它们,例如 谢谢。我一直靠自己解决问题。Wagtail需要更新他们的文档,使其更加具体,但以下是我在blog/blog_page.html中使用的代码: {% extends "base.html" %} {% load wagtailcore_tags wagtailimages_tags %}
谢谢。我一直靠自己解决问题。Wagtail需要更新他们的文档,使其更加具体,但以下是我在
blog/blog_page.html
中使用的代码:
{% extends "base.html" %}
{% load wagtailcore_tags wagtailimages_tags %}
{% block body_class %}template-blogpage{% endblock %}
{% block content %}
<h1>{{ page.title }}</h1>
<p class="meta">{{ page.date }}</p>
{% with categories=page.categories.all %}
{% if categories %}
<h3>Posted in:</h3>
<ul>
{% for category in categories %}
<li style="display: inline">
{% image category.icon fill-32x32 style="vertical-align: middle" %}
{{ category.name }}
</li>
{% endfor %}
</ul>
{% endif %}
{% endwith %}
{% if page.tags.all.count %}
<div class="tags">
<h3>Tags</h3>
{% for tag in page.tags.all %}
<a href="{% slugurl 'tags' %}?tag={{ tag }}"><button type="button">{{ tag }}<$
{% endfor %}
</div>
{% endif %}
<div class="intro">{{ page.intro }}</div>
{{ page.body|richtext }}
{% for item in page.gallery_images.all %}
<div style="float: left; margin: 10px">
{% image item.image fill-320x240 %}
<p>{{ item.caption }}</p>
</div>
{% endfor %}
<p><a href="{{ page.get_parent.url }}">Return to blog</a></p>
{% endblock %}
{%extends“base.html”%}
{%load wagtailcore_tags wagtailimages_tags%}
{%block body_class%}模板blogpage{%endblock%}
{%block content%}
{{page.title}}
{categories%%中的类别为%s}
-
{%image category.icon fill-32x32 style=“垂直对齐:中间”%}
{{category.name}
{%endfor%}
{%endif%}
{%endwith%}
{%if page.tags.all.count%}
标签
{page.tags.all%中标记的%s}
{%endblock%}
{%with categories=page.categories.all%}
{%if类别%}
张贴于: