view gpp/templates/polls/poll_vote.html @ 314:03b70aa5c872

The home page was taking 27 seconds to load; 99% of the time was being spent in the new_posts template tag query. Reworked it a bit to be much more sane.
author Brian Neal <bgneal@gmail.com>
date Sat, 29 Jan 2011 20:34:36 +0000
parents 88b2b9cb8c1f
children 1f139de929c4
line wrap: on
line source
{% extends 'base.html' %}
{% load url from future %}
{% block title %}Polls: {{ poll.question }}{% endblock %}
{% block custom_css %}
<link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}css/polls.css" />
{% endblock %}
{% block content %}
<h2>Poll</h2>
<h3>{{ poll.question }}</h3>
<form action="." method="post">{% csrf_token %}
   <div class="poll-form">
   {{ vote_form.as_p }}
   <input type="submit" value="Vote" />
   </div>
</form>
<p class="poll-nav">
<a href="{{ poll.get_absolute_url }}">Poll Details</a>
| <a href="{% url 'polls.views.poll_results' poll.id %}">View Results</a>
| <a href="{% url 'polls.views.poll_index' %}">Poll Index</a>
</p>
<p>This poll was published on {{ poll.start_date|date:"F d, Y" }}.</p>
{% endblock %}