Dowload a file using a button

I already have a file being written with some values ​​in my Public folder of raspberry(/home/pi/public), also I have set the static to (httpStatic: '/ home / pi / public') on settings.js, now I want to create a button so the user can download the file, I tried this code: (<a href="/StorageData.xlsx" download="StorageData.xlsx"> Download Text </a>) and it informs an error that the file can not be obtained. Can anybody help me?

Thanks

Wrap code samples in backticks (`) so they get formatted properly. Otherwise the < > will get stripped off.

1 Like

If you put, in the browser url, <ip>:1880/StorageData.xlsx does it find the file?

I had the solution, the problem was in the static folder! thank you