Filename clickable to download

This commit is contained in:
discomrade 2021-06-30 09:13:11 -02:00 committed by towards-a-new-leftypol
parent 1073803c74
commit b12f96952a

View File

@ -22,9 +22,9 @@
{% if config.show_filename and file.filename %} {% if config.show_filename and file.filename %}
, ,
{% if file.filename|length > config.max_filename_display %} {% if file.filename|length > config.max_filename_display %}
<span class="postfilename" title="{{ file.filename|e|bidi_cleanup }}">{{ file.filename|truncate_filename(config.max_filename_display)|e|bidi_cleanup }}</span> <a href="{{ config.uri_img }}{{ file.file }}" download="{{ file.filename }}" title="Save as original filename">{{ file.filename|truncate_filename(config.max_filename_display)|e|bidi_cleanup }}</a>
{% else %} {% else %}
<span class="postfilename">{{ file.filename|e|bidi_cleanup }}</span> <a href="{{ config.uri_img }}{{ file.file }}" download="{{ file.filename }}" title="Save as original filename">{{ file.filename|e|bidi_cleanup }}</a>
{% endif %} {% endif %}
{% endif %} {% endif %}
) )
@ -36,3 +36,4 @@
{% endfor %} {% endfor %}
</div> </div>
{% endif %} {% endif %}