http - Restrict access to static files in NGINX by PHP business logic? -


i have nginx web-server , php business logic. want allow access static files (images, media) users.

the authentication rules defined in php.

i understand achievable via serving static files through php. cost in low performance.

is there alternative approach?

solved task using x-sendfile feature. more here: https://www.nginx.com/resources/wiki/start/topics/examples/xsendfile/


Comments

Popular posts from this blog

java - Date formats difference between yyyy-MM-dd'T'HH:mm:ss and yyyy-MM-dd'T'HH:mm:ssXXX -

c# - Get rid of xmlns attribute when adding node to existing xml -