server question

Discussion in 'Technology' started by fidlerre, Jan 10, 2004.

  1. fidlerre

    fidlerre Member+

    Oct 10, 2000
    Central Ohio
    alright so i have a web site:

    http://www.richardefidler.com

    on the server i have a sub-directory for all the images stored on my site:

    http://www.richardefidler.com/images

    here is the thing i would like to do: i want it where that sub-directory cannot be viewed by just anyone. ya know, i don't want people to get an "index" with all my image files listed when they click on that second link.

    i am sure it is some easy fix to make it private or whatever, but i cannot seem to figure it out. anyone care to help a brother out?
     
  2. Foosinho

    Foosinho New Member

    Jan 11, 1999
    New Albany, OH
    Club:
    Columbus Crew
    Nat'l Team:
    United States
    Well, if you can edit the conf file (and the server is apache) just add this:

    <Directory "/real/path/to/directory">
    Options -Indexes
    </Directory>

    If you want, you could create a file ".htaccess" in that images directory, and just put the line

    Options -Indexes

    in there. If your server isn't Apache, I don't know what to tell you.
     

Share This Page