Skip to content

Instantly share code, notes, and snippets.

@grobertson
Created March 24, 2014 14:51
Show Gist options
  • Save grobertson/9741614 to your computer and use it in GitHub Desktop.
Save grobertson/9741614 to your computer and use it in GitHub Desktop.
{% load media %}
{% block meta %}
{# Meta items within this block are dynamic. Things like facebook app_id which persist across all pages are found in base.html #}
{% if article_detail.title %}
{# This is a single article #}
{% include "site/meta/article.html" %}
{% elif comic.title %}
{# This is a single comic #}
{% include "site/meta/comic.html" %}
{% elif comic_artist.name %}
{# This is a page of comics from a single artist #}
{% include "site/meta/comic_artist.html" %}
{% elif comics %}
{# This is all comics from all artists #}
{% include "site/meta/comic_all.html" %}
{% elif kind == 'communities' %}
{# TODO: Continue to improve by making specific templates for tag and community. #}
{% include "site/meta/section.html" %}
{% elif kind == 'topics' %}
{% include "site/meta/section.html" %}
{% elif kind == 'tags' %}
{% include "site/meta/section.html" %}
{% elif section_0.slug == 'latest' %}
{% include "site/meta/latest.html" %}
{% else %}
{# The homepage #}
{% include "site/meta/home.html" %}
{% endif %}
{% endblock meta %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment