diff options
author | Markus Zapke-Grùˆndemann <info@keimlink.de> | 2012-01-09 07:25:19 +0100 |
---|---|---|
committer | Markus Zapke-Grùˆndemann <info@keimlink.de> | 2012-01-09 07:25:19 +0100 |
commit | 2126f86d4d83409311e264dbaf93facf435a505b (patch) | |
tree | 814d108bc4977c70fb26b5247bae9ad8fe89f8f6 /sublab_project/news/templates/news/news_list.html | |
parent | d8e87d205cfda78460c7078dd980a22572b9111b (diff) |
Added thumbnails for news.
Diffstat (limited to 'sublab_project/news/templates/news/news_list.html')
-rw-r--r-- | sublab_project/news/templates/news/news_list.html | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/sublab_project/news/templates/news/news_list.html b/sublab_project/news/templates/news/news_list.html index af66c07..fa11311 100644 --- a/sublab_project/news/templates/news/news_list.html +++ b/sublab_project/news/templates/news/news_list.html @@ -1,4 +1,5 @@ {% extends 'base.html' %} +{% load thumbnail %} {% block title %}Neues{% endblock %} @@ -10,7 +11,11 @@ </h3> {% if post.image %} <div class="imagecontent"> - <img src="{{ MEDIA_URL }}{{ post.image }}" width="{{ post.image_width }}" height="{{ post.image_height }}" align="right" /> + <a href="{{ post.get_absolute_url }}"> + {% thumbnail post.image "200" upscale=False as image %} + <img src="{{ image.url }}" width="{{ image.width }}" height="{{ image.height }}" align="right" /> + {% endthumbnail %} + </a> </div> {% endif %} {{ post.content_html|safe }} |