well, with .htaccess in Apache you can dis/allow access to certain folders to certain users.
In my case I put ZIP-files into a folder and send a link directly to someone else for downloading, not integrated into a webpage. I would like to make this entire folder password secured.
And I also would like to block complete IP-Ranges to access the server. I have no customers in China or Romania, but my server gets scanned day by day from machines over there. I feel okay since there is no PHPmyAdmin script running in my NTWS<vbg>, but I still dislike that and want to block them.
I know that I can set permissions, but that covers browses and forms only, is not covering a folder in general or even the entire webserver.
Was that somehow understandable.
Oh, and as we speak about that.... DIRECTORY
In the server-settings I can define the startpage, it is set by default to 'index.htm'. So, when I type
www.myserver.com the server automatically returns
www.myserver.com/index.htm.
In case I have a folder, lets say "dowloads" and this folder contains a file "index.htm", and now the user types
www.myserver.com/downloads he receives an error 404. Despite the fact that an index.htm exists. The Apache returns that file automatically. If not present, it returns a 404 also.
DIRECTORY can hold several file names, the server has to check one after the other, in case he can find the first one. hmmmmmm, what?
okay - lets say the DIRECTORY has this list of names: index.htm index.html start.htm start.html.
The server looks for index.htm first. If not found, he tries the next, index.html. If not found, the next is requested: start.htm and so on. If none of the files is found, _then_ the Apache returns 404. Its for the convenience.....