I need the .wav file that is created in the "static" folder to be able to be downloaded via a link inserted via HTML or viewed via FileResponse.
I tried things like:
<a href="{% static 'files/{{ filename }}' %}">Download: {{ filename }} </a>
But this didn’t work because it doesn’t find the resource.
2
Answers
You try this code to solve your issue:
As others pointed out make sure where to store your files.
After that You should add
download
attribute to your anchor tag. linkstatic files:
media files:
If you store your media files in the filesystem of your django app, you can use url tag