Mercurial > public > sg101
annotate gpp/templates/news/index.html @ 507:8631d32e6b16
Some users are still having problems with the pop-up login. I think they are actually getting 403s because of the CSRF protection. So I have modified the base template to always have a javascript variable called csrf_token available when they aren't logged in. The ajax_login.js script was then modified to send this value with the ajax post. Fingers crossed.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Sun, 04 Dec 2011 03:05:21 +0000 |
parents | f0f3966ea44f |
children |
rev | line source |
---|---|
gremmie@1 | 1 {% extends 'news/base.html' %} |
bgneal@484 | 2 {% load script_tags %} |
gremmie@1 | 3 {% block title %}News: {{ title }}{% endblock %} |
gremmie@1 | 4 {% block news_css %} |
bgneal@312 | 5 <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}css/pagination.css" /> |
gremmie@1 | 6 {% endblock %} |
bgneal@490 | 7 {% block begin_body %}{% include 'core/social_sharing_begin.html' %}{% endblock %} |
gremmie@1 | 8 {% block news_content %} |
gremmie@1 | 9 <h3>{{ title }}</h3> |
gremmie@1 | 10 |
bgneal@240 | 11 {% if page.object_list %} |
gremmie@1 | 12 {% include 'core/pagination.html' %} |
gremmie@1 | 13 {% for story in page.object_list %} |
gremmie@1 | 14 {% include 'news/story_summary.html' %} |
gremmie@1 | 15 {% endfor %} |
bgneal@240 | 16 {% include 'core/pagination.html' %} |
gremmie@1 | 17 <div style="clear:right;"></div> |
gremmie@1 | 18 {% else %} |
bgneal@240 | 19 <p>No news at this time.</p> |
gremmie@1 | 20 {% endif %} |
gremmie@1 | 21 |
gremmie@1 | 22 {% endblock %} |
bgneal@490 | 23 {% block end_body %}{% include 'core/social_sharing_end.html' %}{% endblock %} |