Skip to content
Grav 2.0 is officially stable. Read the announcement →
Archive

Adding image alt tag to twig template

Started by Muut Archive 9 years ago · 1 replies · 686 views
9 years ago

Can't find a way to add an alt"" tag based on the imagename to every image. In my template i'm adding the images like this:

{% for image in page.media.images %}
<li>
<div class="image-surround">
{{ image.lightbox(1024,768).cropResize(215,215).html }}
</div>
</li>
{% endfor %}

Suggested topics

Topic Participants Replies Views Activity
Archive · by Deleted User, 9 years ago
0 1334 9 years ago
Archive · by Muut Archive, 9 years ago
2 925 9 years ago
Archive · by Muut Archive, 9 years ago
2 4056 9 years ago
Archive · by Muut Archive, 9 years ago
1 2939 9 years ago
Archive · by Muut Archive, 9 years ago
3 1112 9 years ago