Created
March 19, 2012 15:40
-
-
Save adam-davis/2116599 to your computer and use it in GitHub Desktop.
hw for opencampus
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<h2>What's happening near you</h2> | |
{% for newsitem in newsItems %} | |
<div class="row"> | |
<div class="span1"> | |
<p class="latest-schema">{% map_icon_img newsitem.schema %}</p> | |
<p class="latest-month">{{ newsitem.item_date|date:"M" }}</p> | |
<p class="latest-day">{{ newsitem.item_date|date:"d" }}</p> | |
</div> | |
<div class="span7"> | |
<h4>{{ newsitem.title|truncatewords_html:20 }}</h4> | |
{% if newsitem.attributes.photo_href %} | |
<a class="pull-left" href="{{ newsitem.item_url }}" rel="nofollow"><img width="75" height="75" class="thumbnail" src="{{ newsitem.attributes.photo_href }}" alt=""></a> | |
{% endif %} | |
<p>{% if newsitem.description %}{{ newsitem.description|truncatewords_html:25}}{% endif %}</p> | |
<a href="{{ newsitem.item_url}}" class="pull-left">Read more >></a> | |
</div> | |
</div> | |
{% endfor %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% if newsitem_list %} | |
<div id="latest-items"> | |
{% for newsitem in newsitem_list %} | |
<div class="row"> | |
<div class="span1"> | |
</div> | |
<div class="span7"> | |
<h4>{{ newsitem.title|truncatewords_html:20 }}</h4> | |
{% if newsitem.attributes.photo_href %} | |
{% endif %} | |
<p>{% if newsitem.description %}{{ newsitem.description|truncatewords_html:25}}{% endif %}</p> | |
<a href="{{ newsitem.item_url}}" class="pull-left">Read more >></a> | |
</div> | |
</div> | |
{% endfor %} | |
</div><!--/ #latest-items --> | |
{% endif %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% if newsitem_list %} | |
<div id="latest-items"> | |
<ul> | |
{% newsitem_list_by_schema newsitem_list ungrouped %} | |
</ul> | |
</div><!--/ #latest-items --> | |
{% endif %} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment