English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

I'm creating a web site and do not want people to be able to access my list of files on my web space i.e If they try to access a higher level (Say, the folder containing all my image files) to just look through them.

I know I can use a custom made 403 forbidden page but how do I get it to work as such?

I've done a bit of research and it seems that a htaccess file might be what I need, but even if it is I don't know how to create or implement it.

I would be really grateful if anyone could point me in the right direction. Thanks

2007-01-03 08:48:28 · 5 answers · asked by monkeystar 2 in Computers & Internet Programming & Design

5 answers

To block acess to certain folders on your website, you will need to have the .htaccess file and the .htpasswd file.

You can go to the following website:

http://www.tools.dynamicdrive.com/password/

Put in the information such as your user name and your password name. Then in the box where it asks for a directory, place the directory where you want your protected files into that box. When you submit, it will generate codes that you need to copy and paste into your own .htaccess and .htpasswd files.

Upload those new files to your website directory (the directory where you want protected files).

Any other questions, contact me. I am a website designer and I will help you.

2007-01-03 09:59:42 · answer #1 · answered by ? 3 · 0 0

If i am reading your problem right... the easiest way would be not to have links going to the directory. If you are talking about on your computer just place a password on the folder. Also your webspace should have a block that keeps them from doing it anyway... they should get the YOU DON'T HAVE ACCESS page

2007-01-03 09:00:45 · answer #2 · answered by Sentimental Treasures Photo 6 · 0 1

Check the deeds to your property. They should show clearly which parts of the drive are shared and which parts belong to each house. Speak to your neighbour and suggest that, in the interests of harmony between you, you should each keep your own cars on your side of that line and, in future, to advise each other when there are visitors who will need to get their cars off the road. This is a two-way thing and you have to do the same as you are asking your neighbour to do.

2016-03-29 06:19:34 · answer #3 · answered by Deborah 4 · 0 0

Hi,

A quick work-around you could use is to create a blank index.html page and place it in each of your directories - this would stop people being able to browse you images and scripts.

2007-01-03 23:52:09 · answer #4 · answered by Dan B 2 · 0 0

if you want the search engines not to search your "forbidden" directories, create a robots.txt file in your top web directory that has similar contents as follow:

User-agent: *
Disallow: /css/
Disallow: /lib/
Disallow: /music/
Disallow: /pics/
Disallow: /scripts/

You can find out what it is at http://en.wikipedia.org/wiki/Robots.txt
or http://www.robotstxt.org/wc/robots.html

2007-01-03 19:48:57 · answer #5 · answered by Zenithia 3 · 0 0

fedest.com, questions and answers