
{% extends "newsroom/base.html" %}

{% block og_title %}{{archive.title}}{% endblock %}
{% block og_type %}Article{% endblock %}
{% block og_url %}{{archive.get_absolute_url}}{% endblock %}
{% block og_description %}{{archive.description}}{% endblock %}
{% block og_image %}{{MEDIA_URL}}images/headers/pbp_sharing_logo.jpg{% endblock %}

{% block title %}{{archive.title}} | Community News Archives | Penobscot Bay Press{% endblock %}
{% block description %}{{archive.body|truncatewords:60}} {% endblock %}
{% block flag_img_src %}{{MEDIA_URL}}images/headers/archivesround440.gif{% endblock %}
{% block flag_descrip %}Short-term archives, videos, slideshows and special features {% endblock %}
{% block content %}
{% load markup typogrify humanize %}
<div style="width:100%; margin:0; padding:0">
	<div class="main_content_left">
		<div style="padding-left:12px; padding-right:12px; padding-top:12px">
			<h2 class="sectionhead_wide"><em>{{ archive.paper }}</em> Archives</h2>
		</div>
 		<div style="padding-left:12px; padding-right:12px; padding-top:12px">
                  {% if archive.lead_image %}
                  <h1><img src="{{archive.lead_image.url}}" alt="{{archive}}"/></span></h1>
                  {% else %} 
                 <h1>{{archive.title}}</SPAN></h1> 
                  {% endif %}
                  <SPAN Class="teaser">{{archive.dateline}}</SPAN><br>
                  </SPAN><SPAN Class="headline">{{archive|cut:"archive"}}</SPAN>
                  {{archive.description|markdown|typogrify}}

        {% if archive.pdf_documents.all %}
        <p><span class="dirservfeatured">Documents</span></p> 
        <ol> 
            {% for doc in archive.pdf_documents.all|dictsortreversed:"published_on" %}
            <li><a href="{{doc.get_absolute_url}}" class="archive">{{doc.title}}</a><br>
            <span class="paper"> {% for e in doc.webedition_set.all %}{% if forloop.first %}<em>{{e.paper}}</em>, {{e.published_on|date:"n/j/y"}}{% endif %}{% endfor %}</span>

            </li> 
            {% endfor %}
        </ol>
        {% endif %}

        {% if archive.movies.all %}
        <p><span class="dirservfeatured">Movies</span></p> 
        <ol> 
            {% for movie in archive.movies.all %}
            <li><a href="{{movie.get_absolute_url}}" class="archive">{{movie.title}}</a></li> 
            {% endfor %}
        </ol>

        {% endif %}

        {% if archive.slideshows.all %}
        <p><span class="dirservfeatured">Slideshows</span></p> 
        <ol> 
            {% for ss in archive.slideshows.all %}
            <li><a href="{{ss.get_absolute_url}}" class="archive">{{ss.title}}</a></li> 
            {% endfor %}
        </ol>
        {% endif %}

        {% if archive.galleries.all %}
        <p><span class="dirservfeatured">Galleries</span></p> 
        <ol> 
            {% for gallery in archive.galleries.all %}
            <li><a href="{{gallery.get_absolute_url}}" class="archive">{{gallery.title}}</a></li> 
            {% endfor %}
        </ol>
        {% endif %}
        {% if archive.photos.all %}
        <p><span class="dirservfeatured">Photos</span></p> 
        <ol> 
            {% for photo in archive.photos.all %}
            <li><a href="{{photo.get_absolute_url}}" class="archive">{{photo.title}}</a></li> 
            {% endfor %}

        </ol>
        {% endif %}

        {% if archive.stories.all %}
        {% if archive.group_by == 'type' %}
        <p><span class="dirservfeatured">Articles</span></p> 
        <ol> 
            {% for article in archive.stories.all|dictsortreversed:"published_on" %}
            <li><a href="{{article.site.domain}}{{article.get_absolute_url}}" class="archive">{{article.hed}}</a><br />
			<span class="paper">{% for e in article.paper_editions.all %}{% if forloop.first %}<em>{{e.paper}}</em>, {{e.published_on|date:"n/j/y"}}{% endif %}{% endfor %}</span>
			</li> 
            {% endfor %}
        </ol>
        {% else %}
        {% if archive.group_by == 'dline' %}
        {% regroup archive.stories.all|dictsort:"dateline.title" by dateline as dateline_list %}
        <p><span class="archivesection">Articles</span></p> 
        {% for dline in dateline_list %}
        <p><span class="teaser">{{dline.grouper}}</span></p>
        <ol>
            {% for article in dline.list|dictsortreversed:"published_on" %}
            <li><a href="{{article.site.domain}}{{article.get_absolute_url}}" class="archive">{{article.hed}}</a><br />
			<span class="paper">{% for e in article.webedition_set.all %}{% if forloop.first %}<em>{{e.paper}}</em>, {{e.published_on|date:"n/j/y"}}{% endif %}{% endfor %}</span>
			</li> 
            {% endfor %}
        </ol>
        {% endfor %} 
        {% else %}
        {% endif %}
        {% endif %}
        {% endif %}

        {% if archive.editorials.all %}
        {% if archive.group_by == 'type' %}
        <p><span class="dirservfeatured">Opinion</span></p> 
        <ol> 
            {% for opinion in archive.editorials.all %}
            <li><a href="{{opinion.get_absolute_url}}" class="archive">{{opinion.hed}}</a><br />
            <span class="paper"> {% for e in opinion.webedition_set.all %}{% if forloop.first %}<em>{{e.paper}}</em>, {{e.published_on|date:"n/j/y"}}{% endif %}{% endfor %}</span>
            {% endfor %}
        </ol> 
        {% else %}
        {% if archive.group_by == 'dline' %}
        {% regroup archive.editorials.all|dictsort:"dateline.title" by dateline as dateline_list %}
        <p><span class="archivesection">Opinion</span></p> 
        {% for dline in dateline_list %}
        <p><span class="teaser">{{dline.grouper}}</span></p>
        <ol> 
            {% for opinion in dline.list|dictsortreversed:"published_on" %}
            <li><a href="{{opinion.get_absolute_url}}" class="archive">{{opinion.hed}}</a><br />
            <span class="paper"> {% for e in opinion.webedition_set.all %}{% if forloop.first %}<em>{{e.paper}}</em>, {{e.published_on|date:"n/j/y"}}{% endif %}{% endfor %}</span>
            {% endfor %}
        </ol> 
        {% endfor %}
        {% endif %}
        {% endif %}
        {% endif %}
    </div> 
<div style="padding-left:12px; padding-right:12px; clear:both">

<p><a class="return" href="{%url nr-index %}">Return to the Community News home page.</a></p> 
</div>				

</div>
</div>
<div class="sidebar_right_media" style="background-color:#99CCFF; padding:0px">
	<div style="padding:4px; text-align:center; margin:0px 0px 10px 0px">
		<p class="relatedstory">{% if archive.slug == 'dishs-sports-archive' %}<a href="http://penobscotbaypress.smugmug.com/Galleries/DISHS-Sports">Order Sports Photos</a>{% elif archive.slug == 'gsa-sports-archive' %}<a href="http://penobscotbaypress.smugmug.com/Galleries/GSA-Sports">Order Sports Photos</a>{% elif archive.slug == 'mma-sports-archive' %}<a href="http://penobscotbaypress.smugmug.com/Galleries/MMA-Sports">Order Sports Photos</a>{% else %}<a href="http://penobscotbaypress.smugmug.com">Order Photos</a>{% endif %}</p>
		<div class="newcutline"><strong>{% if archive.slug == 'dishs-sports-archive' %}Order prints of your favorite DISHS sports photos!{% elif archive.slug == 'gsa-sports-archive' %}Order prints of your favorite GSA sports photos!{% elif archive.slug == 'mma-sports-archive' %}Order prints of your favorite MMA sports photos!{% else %}Order many of the photos you see on our website and then some!{% endif %}</strong><br><br>
		Most prints start at $1 and are delivered directly to you. Print your favorite newspaper photos on a mug, a t-shirt, or even poster size. Browse by publication date, keyword search or the individual galleries. Share your favorite photos to social media or download a link to share with all your friends and family.</span></div>
		<a href="http://penobscotbaypress.smugmug.com/" class="head_link"><img src="https://penobscotbaypress.com/static/images/headers/2013/smugmug_teaser_img_2014_blue.jpg"></a>
	</div>
</div>
	<div class="sidebar_right_media">
		<!-- Google AdSense BEGIN -->
		<div style="clear:both; text-align:center">
			<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
			<!-- Square ad for right of pages -->
			<ins class="adsbygoogle"
			style="display:inline-block;width:250px;height:250px"
			data-ad-client="ca-pub-7616595738812584"
			data-ad-slot="7790117357"></ins>
			<script>
			(adsbygoogle = window.adsbygoogle || []).push({});
			</script>
		</div>
		<!-- Google AdSense END -->
		<br>
		<!-- Google AdSense BEGIN -->
		<div style="clear:both; text-align:center">
			<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
			<!-- Square ad for right of pages -->
			<ins class="adsbygoogle"
			style="display:inline-block;width:250px;height:250px"
			data-ad-client="ca-pub-7616595738812584"
			data-ad-slot="7790117357"></ins>
			<script>
			(adsbygoogle = window.adsbygoogle || []).push({});
			</script>
		</div>
		<!-- Google AdSense END -->
	</div>
<!-- AddThis Smart Layers BEGIN -->
<!-- Go to http://www.addthis.com/get/smart-layers to customize -->
<script type="text/javascript" src="//s7.addthis.com/js/300/addthis_widget.js#pubid=penbaypress"></script>
<script type="text/javascript">
addthis.layers({
'theme' : 'transparent',
'share' : {
'position' : 'right',
'services' : 'facebook,twitter,email,print,gmail,tumblr,more',
}   
});
</script>
<!-- AddThis Smart Layers END -->
{% endblock %}
