Skip to content

Latest commit

 

History

History
51 lines (49 loc) · 1.59 KB

archivebycategory.md

File metadata and controls

51 lines (49 loc) · 1.59 KB
title class layout current permalink
Rails Girls Summer of Code Archive by category
page archive
bootstrap
categoryview
/blog/categoryview/

Browse by category

{% assign categories = site.categories | sort %}
<div id="index">
  <ul class="list--archive list--none">
    {% for category in categories %}
      {% if category[0] != 'blog' %}
        <a name="{{ category[0] }}"></a><h3>{{ category[0] | replace:'-', ' ' }} ({{ category | last | size }}) </h3>
        {% assign sorted_posts = site.posts | sort: 'date' | reverse %}
        {% for post in sorted_posts %}
          {%if post.categories contains category[0]%}
          <li>
            {{ post.date | date:"%d %b %Y" }} <a href="{{ post.url }}" title="{{ post.title }}">{{ post.title }}</a>
             <p>{{ post.excerpt | strip_html | truncate: 160 }}</p>
          </li>
          {%endif%}
        {% endfor %}
      {% endif %}
    {% endfor %}
  </ul>
</div>
{% include blog_sidebar.html %}