How would I go about running a PHP file that is only matched by the request of that file? Meaning, how can someone request a file and nginx run this configuration ONLY when this PHP file is requested.
Here is what I have so far:
[code]
location / {
root /www/default/;
try_files $uri $uri/ /index.php?q=$uri&$args;
index index.php;
}
location /status.php {
#allow 192.168.1.0/24;
deny all;
#allow all;
root /www/default/;
try_files $uri $uri/ /index.php?q=$uri&$args;
index status.php;
}
[/code]
Basically, I'll be setting up rules to only allow a local network request, but only for status.php. So how do I go about allowing this one network to status.php?