So confused!!

zimu

Diamond Member
Jun 15, 2001
6,209
0
0
I'm so confused!!

Ok so i've got this folder "users" and inside it i've got a folder "test"

Now how can I make it (chmod-wise) so that if you go to the web, you cannot see the directories in either users OR test, but be able to go to anything in test without problem. On top of that, if "Test" does not have a homepage, just files, i don't want to be able to see those files?!

I know its something to do with the "other" part of chmod, i've tried just read, just execute, neither, and none of them give me what i want! i want all directory structures (i.e. contents) to be private but you can link directly to a file in the directory iwhtout hassle, or load index.html?
 

GtPrOjEcTX

Lifer
Jul 3, 2001
10,784
6
81
fast way? stick a blank file called index.htm in each of the folders.

alternate way, are you using cpanel? if so goto the "index manager" and do it from there.
 

randomlinh

Lifer
Oct 9, 1999
20,846
2
0
linh.wordpress.com
the real way is to use a .htaccess file. Create a file ".htaccess"

if the file contains this:
Options +Indexes
IndexOptions NameWidth=*

you can view directories. To hide the directory so you can only access things via a direct link, do this:
Options -Indexes


That should work. Stick it in the directory you want to hide. Note that some ftp programs will hide the .htaccess file when you upload it since to it, it's a random extension.
 

ddjkdg

Senior member
Dec 22, 2001
718
0
0
As far as I know, this has nothing to do with chmod, you need to use the .htaccess file.
 

GtPrOjEcTX

Lifer
Jul 3, 2001
10,784
6
81
Originally posted by: ddjkdg
As far as I know, this has nothing to do with chmod, you need to use the .htaccess file.

he's already got it going....see his other thread about needing the at effect.
 

zimu

Diamond Member
Jun 15, 2001
6,209
0
0
Originally posted by: GtPrOjEcTX
Originally posted by: ddjkdg
As far as I know, this has nothing to do with chmod, you need to use the .htaccess file.

he's already got it going....see his other thread about needing the at effect.

nice and observant!
yes, i managed to get it going. there is an option in cpanel for indexing, i just turned it off. nice and easy! saves chmod and htaccess problems :)