Changeset View
Changeset View
Standalone View
Standalone View
common/templates/common/components/helpers/image_resize.html
| {% load cache %} | {% load cache %} | ||||
| {% load thumbnail %} | {% load thumbnail %} | ||||
| {% cache 500 thumbnails img_source classes width %} | {% cache 500 thumbnails img_source classes width %} | ||||
| <img | <img | ||||
| src="{% thumbnail img_source width as im %}{{ im.url }}{% endthumbnail %}" | src="{% thumbnail img_source width as im %}{{ im.url }}{% endthumbnail %}" | ||||
| class="{{ classes }} {% if img_source and img_source|is_portrait %}portrait{% endif %}" | class="{{ classes }} {% if img_source and img_source|is_portrait %}portrait{% endif %}" | ||||
| alt="{{ alt }}" | alt="{{ alt }}" | ||||
| > | > | ||||
| {% endcache %} | {% endcache %} | ||||