Mercurial > public > sg101
comparison gpp/templates/news/story_summary.html @ 5:63696b279e35
Display news links and send to friend on the summary page. Use icons.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Sat, 11 Apr 2009 19:45:17 +0000 |
parents | dbd703f7d63a |
children | c284c0e5c5db |
comparison
equal
deleted
inserted
replaced
4:9a8801fa63d5 | 5:63696b279e35 |
---|---|
1 {% load comment_tags %} | 1 {% load comment_tags %} |
2 {% get_comment_count for story as comment_count %} | 2 {% get_comment_count for story as comment_count %} |
3 <div class="news-story-container"> | 3 <div class="news-story-container"> |
4 <h4><a href="{% url news.views.story story.id %}">{{ story.title }}</a></h4> | 4 <h4><a href="{{ story.get_absolute_url }}">{{ story.title }}</a></h4> |
5 <div class="news-details"> | 5 <div class="news-details"> |
6 Submitted by {{ story.submitter.username }} on {{ story.date_published|date:"F d, Y" }}. | 6 Submitted by {{ story.submitter.username }} on {{ story.date_published|date:"F d, Y" }}. |
7 </div> | 7 </div> |
8 <a href="{% url news.views.category category=story.category.id,page=1 %}"> | 8 <a href="{% url news.views.category category=story.category.id,page=1 %}"> |
9 <img src="{{ story.category.icon.url }}" alt="{{ story.category.title }}" title="{{ story.category.title }}" | 9 <img src="{{ story.category.icon.url }}" alt="{{ story.category.title }}" title="{{ story.category.title }}" |
10 class="news-icon" /></a> | 10 class="news-icon" /></a> |
11 <div class="news-content"> | 11 <div class="news-content"> |
12 {{ story.short_text|safe }} | 12 {{ story.short_text|safe }} |
13 </div> | 13 </div> |
14 {% if story.long_text %} | |
14 <p> | 15 <p> |
15 {% if story.long_text or comment_count %} | 16 <img src="{{ MEDIA_URL }}icons/bullet_go.png" alt="Read More" /> |
16 <a href="{% url news.views.story story.id %}">Read more...</a> | | 17 <a href="{{ story.get_absolute_url }}">There is more to this story, continue reading ...</a> |
18 </p> | |
17 {% endif %} | 19 {% endif %} |
18 <a href="{% url news.views.story story.id %}">{{ comment_count }} comment{{ comment_count|pluralize }}</a>. | 20 <hr /> |
21 <p> | |
22 <img src="{{ MEDIA_URL }}icons/comments.png" alt="Comments" /> | |
23 <a href="{{ story.get_absolute_url }}">{{ comment_count }} comment{{ comment_count|pluralize }}</a> | |
24 <a href="{{ story.get_absolute_url }}"><img src="{{ MEDIA_URL }}icons/link.png" alt="Permalink" title="Permalink" /></a> | |
25 {% if user.is_authenticated %} | |
26 <a href="{% url news.views.email_story story.id %}"><img src="{{ MEDIA_URL }}icons/email_go.png" | |
27 alt="Send this story to a friend" title="Send this story to a friend" /></a> | |
28 {% endif %} | |
19 </p> | 29 </p> |
20 {% if story_tags %} | 30 {% if story_tags %} |
21 <div class="news-tags"> | 31 <div class="news-tags"> |
22 <span>Tags:</span> | 32 <img src="{{ MEDIA_URL }}icons/tag_blue.png" alt="Tags" title="Tags" /> |
23 <ul> | 33 <ul> |
24 {% for tag in story_tags %} | 34 {% for tag in story_tags %} |
25 <li><a href="{% url news-tag_page tag_name=tag.name,page=1 %}">{{ tag.name }}</a></li> | 35 <li><a href="{% url news-tag_page tag_name=tag.name,page=1 %}">{{ tag.name }}</a></li> |
26 {% endfor %} | 36 {% endfor %} |
27 </ul> | 37 </ul> |