23👍
✅
Try this way (added with
statement with stringformat on top of yours):
{% with vid.the_id|stringformat:"s" as vid_id %}
{% with "image-"|add:vid_id as image_id %}
{# custom template tag to generate image #}
{% image vid.teaser_thumbnail alt=vid.title id=image_id %}
{% endwith %}
{% endwith %}
Source:stackexchange.com