Forum Moderators: phranque

Message Too Old, No Replies

Hide files on apache webserver

Howto?

         

Ruben

12:38 pm on Dec 4, 2005 (gmt 0)

10+ Year Member



Can someone please explain how to hide some files on my apache webserver if I log in with ftp to the server? So the file in question must be hidden.

skinter

2:18 am on Dec 5, 2005 (gmt 0)

10+ Year Member



The only thing I can think of (and this would require that your client not have an option to show this), would be to add a period (.) before the file. IE, test.txt becomes .test.txt .

This would only work on *NIX OS, and would require the FTP client only show normal files/directories.

Besides, even if by default those files were invisible to the client, there is usually an option to enable viewing them.
Or if you connected through a console, all you'd have to do is 'ls -a'.

mack

2:41 am on Dec 5, 2005 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



Do you only want them to be invisible to browsers? If so you coucl burry them bellow your public_html folder. The browser cant go any lower than this location if the servers virtual host has been configured correctly.

Mack.

marcs

5:33 am on Dec 5, 2005 (gmt 0)

10+ Year Member



You could also create a directory inside your web/html directory and chmod it to 700. Place your files in that directory. That should make them inaccesible by web browsers.