Re: Block direct access to .inc files not working

2016-02-21 Thread dust2
You should block access in php file. For example: You define using defined ( 'ACCESS'... in any file you want direct access and put the line below to every php files: defined ( 'ACCESS' ) or die ( 'Restricted Access' ); Posted at Nginx Forum: https://forum.nginx.org/read.php?2,264663,264694#msg-

Re: Block direct access to .inc files not working

2016-02-20 Thread rsclmumbai
@dewanggaba Perfect. That worked like a charm. Thanks! Posted at Nginx Forum: https://forum.nginx.org/read.php?2,264663,264680#msg-264680 ___ nginx mailing list nginx@nginx.org http://mailman.nginx.org/mailman/listinfo/nginx

Re: Block direct access to .inc files not working

2016-02-20 Thread Dewangga Alam
Hello! On 2/20/2016 4:07 PM, rsclmumbai wrote: I've a nginx server on CentOS with PHP setup. I'm trying to block direct access to .inc files I've added the following to nginx.conf location ~ /\.inc { deny all;

Block direct access to .inc files not working

2016-02-20 Thread rsclmumbai
I've a nginx server on CentOS with PHP setup. I'm trying to block direct access to .inc files I've added the following to nginx.conf location ~ /\.inc { deny all; } & restarted nginx. But I