<?py include('header.html', body_ext=' id="archive"') ?>

<div id="main">
    <div id="content">
      <div>

<article role="article">

  <header>
    <h1 class="entry-title">Tag: #{tobj["name"]}</h1>
  </header>

  <div id="blog-archives" class="category">

<?py year = 0 ?>
<?py for obj in objs: ?>
<?py     pmdy = get_post_mdy(obj['add_time']) ?>
<?py     if pmdy[2] != year: ?>
<?py         year = pmdy[2] ?>
  <h2>#{year}</h2>
<?py     #endif ?>

<article >
<h1 class="entry-title"><a href="/topic/#{obj['id']}/#{quoted_string(obj['title'])}">#{obj["title"]}</a></h1>
<time datetime="#{detail_date_tzd(obj['add_time'])}" pubdate><span class='month'>#{pmdy[0]}</span> <span class='day'>#{pmdy[1]}</span> <span class='year'>#{pmdy[2]}</span></time>
<footer><span class="categories">posted with tag <a class="category" href="/tag/#{qt}">#{tobj["name"]}</a></span></footer>
</article>

<?py #endfor ?>

  <div class="pagination">
<?py if page < total_page: ?>
    <a class="prev" href="/tag/#{qt}?page=#{page+1}">← Older</a>
<?py #endif ?>
<?py if page > 1: ?>
    <a class="next" href="/tag/#{qt}?page=#{page-1}">Newer →</a>
<?py #endif ?>

  </div>

</article >

</div>

<?py include('sidebar.html') ?>

    </div>
</div>

<?py include('footer.html') ?>
