Bradley M. Kuhn
09a4b021c1
During the recent improvements made on the website, the menus and submenu highlighting for selected menus fell into disarray. Correction requires changes to the CSS and templates both, because Django doesn't really have a convenient way to set variables in templates to use to solve this. There are still a few submenu items highlighting not working even after this commit. More work needs to be done.
45 lines
2 KiB
HTML
45 lines
2 KiB
HTML
{% extends "base_news.html" %}
|
|
{% block subtitle %}News - {% endblock %}
|
|
|
|
{% block outercontent %}
|
|
<div id="container">
|
|
<div id="sidebar" class="{% block submenuselection %}{% endblock %}">
|
|
<h2>News Index by Year</h2>
|
|
<ul>
|
|
{% for year in date_list reversed %}<li class="{{ year|date:"Y" }}"><a href="{{ year|date:"Y" }}/">{{ year|date:"Y" }}</a></li>{% endfor %}
|
|
</ul>
|
|
<h2>Resources for Journalists</h2>
|
|
<ul>
|
|
<li class="News"><a href="/news/">News</a></li>
|
|
<li class="PressKit"><a href="/press/">Press Kit</a></li>
|
|
<li class="Glossary"><a href="/copyleft-compliance/glossary.html">Glossary</a></li>
|
|
</ul>
|
|
|
|
</div>
|
|
<div id="mainContent">
|
|
<div class="breadcrumbs">
|
|
<p><a href="/">Home</a> / <a href="/news/">News</a></p>
|
|
</div>
|
|
<h1><a href="/feeds/news/" class="feedlink"><img src="/img/feed-icon-14x14.png" alt="[RSS]"/></a> Conservancy News</h1>
|
|
|
|
|
|
{% ifnotequal news.number 1 %}<p>(Page {{ news.number }} of {{ news.paginator.num_pages }})</p>{% endifnotequal %}
|
|
|
|
{% for pressr in news %}
|
|
{% if pressr.is_recent %}
|
|
{% include "news/pressrelease_partial.html" with pressr=pressr show="summary" only %}
|
|
{% else %}
|
|
{% include "news/pressrelease_partial.html" with pressr=pressr show="dateline" only %}
|
|
{% endif %}
|
|
{% endfor %}
|
|
|
|
<p>
|
|
{% if news.has_next %}<a class="next_page_button" href="?page={{ news.next_page_number }}">Next page (older) »</a>{% endif %}
|
|
{% if news.has_previous %}<a href="?page={{ news.previous_page_number }}">« Previous page (newer)</a>{% endif %}
|
|
</p>
|
|
{% if news.paginator.num_pages > 1 %}<p class="pagination_list"> {% for pagenum in news.paginator.page_range %}{% ifequal pagenum news.number %}[{{ pagenum }}]{% else %}<a href="?page={{ pagenum }}">{{ pagenum }}</a>{% endifequal %} {% endfor %}</p>{% endif %}
|
|
</div>
|
|
</div>
|
|
<div class="clear"></div>
|
|
|
|
{% endblock %}
|