{% extends 'layouts/base.njk' %} {% set title = app.name + ' - File upload' %} {% block scripts %} {% endblock %} {% block body %}

Upload files

(except illegal ones)

Upload a file

{{ macros.field(_locals, 'file', 'upload', '', 'Choose wisely', 'The maximum upload size is ' + max_upload_size + 'MiB', validation_attributes='required') }} {{ macros.field(_locals, 'number', 'expire_after_days', '30', 'How many days to delete this file after', null, validation_attributes='max="1825"') }} {{ macros.field(_locals, 'checkbox', 'never_expire', '', 'Never delete this file') }} {{ macros.field(_locals, 'text', 'slug', '', 'Custom url slug', 'Example: beautiful_image.jpg sets url to https://'+default_domain+'/beautiful_image.jpg', validation_attributes='disabled') }} {{ macros.field(_locals, 'checkbox', 'autogen_url', '', 'Generate url automatically', null, validation_attributes='checked') }} {{ macros.csrf(getCsrfToken) }}
{% set url = flash('url') %} {% if url | length %}
URL
{{ url }}
{% endif %}
{% include 'desktop-utility.njk' %} {% endblock %}