Question: I have a set of files on my website with the extension .rpc. They are financial files, and I want to make sure that no one can access them from the web. Can i do that?
Answer: On an Apache server, you can do just about anything, and .htaccess files make a lot of that possible. Simply create an .htaccess file or use the one you already have and add something like this:
<Files ~ "^.*\.([Rr][Pp][Cc])">
Deny from all
The letters are repeated in lowercase and capital to ensure both are blocked. Simply substitute the letters with whatever extension you want to deny. For example:
<Files ~ "^.*\.([Ll][Oo][Gg])"> will deny access to all .log files. It really is that simple.