I try to implement the distribution of files from a protected folder using apache via an internal request through a script in php. Nginx can not use according to the circumstances of the customer. In nginx there is a convenient solution to my problem:

location /dir{ internal; mp3; } 

How can this be done on apache?

  • This unfortunately does not help. File distribution works fine. The question is in the server settings. I need to make it so that when I call through a script, the file is available, and when I request it via a direct link, I return an error. In nginx, this can be achieved using the folder settings. But can this be achieved on apache? - Tatiana
  • Duck, remove it from the web-root in general and everything, obviously like? - teran
  • Yes, it could be done on a dedicated server. But customers simply have ssh access. So all that is available to me is bash scripts and htacess. I edited the question to make my task more visible. - Tatiana

0