Jump to content

.htaccess is driving me crazy!


chigley

Recommended Posts

Hey guys,

 

I hope you can help on this one. I want to block all users (except myself) from accessing all files in the public_html directory. I want anyone who isn't me to be shown a custom error (I assume the 403 error?)

 

The thing is, with my current code, it blocks everyone from viewing everything - including the 403 error page! How can I specify to block everything except 403.shtml?

 

My code is:

 

order deny,allow
deny from all
allow from 82.42.33.56
allow from 85.210.169.252

<Files 403.shtml>
order allow,deny
allow from all
</Files>

 

Thanks a lot,

 

Charlie

Link to comment
https://forums.phpfreaks.com/topic/74337-htaccess-is-driving-me-crazy/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.