cancel
Showing results for 
Search instead for 
Did you mean: 

htaccess deny from all

David_W
Rising Star
Posts: 2,293
Thanks: 29
Registered: 19-07-2007

htaccess deny from all

In my CGI space, I have a directory that I would like to prevent anyone other than me accessing. I created the .htaccess so it looks like:

<Files .htaccess>
order allow,deny
deny from all
</Files>
order deny,allow
deny from all
allow from **.**.**.**

where ** is my real IP address. To test it I tried anonymizer thingy, and got a friend to check if they could still access that directory, and they could. Does anyone know why this does not work please?

And happy new year too btw Smiley
2 REPLIES
N/A

htaccess deny from all

I did a quick test with the script below and seemed OK...

<Files .htaccess> 

deny from all
</Files>
<Files *>
deny from all
allow from w.x.y.z
</Files>
David_W
Rising Star
Posts: 2,293
Thanks: 29
Registered: 19-07-2007

htaccess deny from all

cool, worked like a charm, thanks Smiley