Copy link to clipboard
Copied
Hello All,
A bit of background.
I am an amateur seismologist who has a seismic station which creates triggered event files on a Raspberry Pi.
When an earthquake is detected by the station approximately 5 files are created and placed in a folder which is time and date stamped automatically. I can then analyse these seismograms locally using the relevent software...
The mission.
I have a website which I have developed over the years and now I wish to add these folders containing the data files onto my website so other interested parties can select and download and analyse the seismic events. This is the part I need help with.
This is my first post on here and thanks for reading , Hoping someone can educate me , appreciated.
Copy link to clipboard
Copied
Hi @Cellectronic ,
This is not a Dreamweaver function. It's a server function.
Theoretically, you can add a force download script to the downloads folder on your server. The exact manner will depend on the type of web server and which programming languages it supports.
An example using .htaccess file (Linux/Apache server).
https://stackoverflow.com/questions/14388994/forcing-a-download-using-filesmatch-in-htaccess
Hope that helps.
Copy link to clipboard
Copied
I'm not sure I understand your mission, or at least your question:
Do you want to automate the upload process each time your station creates files, which would imply that the links to these new files are also generated automatically.
In this case, it would be necessary to add to the script used on the Raspberry (by the way Python or JS?) an FTP sending of the created files to a specific folder on the remote server.
Then on the server side, develop a PHP that would list and make accessible as links all the files present in this specific folder (and/or sub-folder).
Or do you want to impose the downloading of the files when the user clicks on the link, and that the browser doesn't try to read them as a page. if this is the case, the discussion on stackoverflow that Nancy proposes is a good idea.