Answer the question
In order to leave comments, you need to log in
How to log a file download from the server via a direct link?
Good afternoon. The file is downloaded from the server via a direct link, is it possible to log these downloads? We need information from which ip the download was and how many times the file is downloaded. It is desirable to implement this somehow using a php script.
Answer the question
In order to leave comments, you need to log in
For example, configure the server so that instead of directly accessing the file, a php script is accessed, which will give the desired file, and at the same time log it. On apache, this can be done using .htaccess, on nginx - in the config
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question