<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>{% block title %}{% endblock %}--博客系统</title>
</head>
<body>
    <div>顶部分类：
        {% for cate in navs %}
            <ul>
{#            <li><a href="/category/{{ cate.id }}/">{{ cate.name }}</a></li>#}
                <li><a href="{% url 'category-list' cate.id %}">{{ cate.name }}</a></li>
            </ul>
        {% endfor %}
    </div>
    <hr />

    {% block main %}
    {% endblock %}

    <hr />
    <div>底部分类：
        {% for cate in categories %}
            <ul>
{#            <li><a href="/category/{{ cate.id }}/">{{ cate.name }}</a></li>#}
            <li><a href="{% url 'category-list' cate.id %}">{{ cate.name }}</a></li>
            </ul>
        {% endfor %}
    </div>

    <hr />
    <div>侧边栏展示：
        {% for sidebar in sidebars %}
            <h4>{{ sidebar.title }}</h4>
            <p>{{ sidebar.content_html }}</p>
        {% endfor %}
    </div>
</body>
</html>