Commits

David Chambers  committed e163158

Added support for custom post types.

  • Participants
  • Parent commits 88be3ab

Comments (0)

Files changed (2)

File templates/page.dhtml

+{% extends 'base.dhtml' %}
+{% block title %}{{ meta.title }}{% endblock %}
+{% block content %}
+				<article>
+					<header>
+						<h1>{{ meta.title }}</h1>
+					</header>
+					{{ html|safe }}
+				</article>
+{% endblock %}
             except disqus.APIError:
                 pass
 
-        return render_to_string('post.dhtml', dict(context, **dict({
+        template = context['meta'].get('type', 'post' if 'datetime' in context['meta'] else 'page')
+        return render_to_string('%s.dhtml' % template, dict(context, **dict({
                     'comments': comments,
                     'form': form,
                     'new_comment': comment,