Non-Recursive .htaccess files?
Enverex
Worcester, UK Icrontian
Is it possible to make .htaccess files non-recursive? i.e.
The folder layout is like this
-Games
|A
..... Aggy
..... Ambly
..... Adalety
..... Ambeint
|B
..... Bertville
..... Baggins
..... Bobs Bad Day
|C
..... Chaos Engine
..... Cabal
..... Cannon Fodder
Now, what I need is JUST the lowest folders (Baggins, Cannon fodder etc) to have directory listings, non the others, but I cant figure out a way how to do this.
Any ideas?
NS
The folder layout is like this
-Games
|A
..... Aggy
..... Ambly
..... Adalety
..... Ambeint
|B
..... Bertville
..... Baggins
..... Bobs Bad Day
|C
..... Chaos Engine
..... Cabal
..... Cannon Fodder
Now, what I need is JUST the lowest folders (Baggins, Cannon fodder etc) to have directory listings, non the others, but I cant figure out a way how to do this.
Any ideas?
NS
0
Comments
a/b/c/index.html
if /a nor /a/b do you want dir listings available, then put the .htaccess file in /a/b/c, not /a or /a/b. Try it and see.
NS
NS
If this were Linux, the easiest thing would be a large number of links to the htaccess file, one link per folder you want excluded (links can be copy-pasted). Ditto BSD. I would try a few soft links, as then you can delete the link and still keep the file in what I had to test with.
I would do this with links or permissions given your large data tree problem. You can fairly easily have subfolders more restricted to specific user than parent folders in things other than Linux(although the reverse is generally NOT true).
A mix of that might work.
It looks like you are using directories to sort instead of indexing in a DB and using a shallow (logical) storage tree structure.
John Danielson.
But the point is, doesnt that idea still involve me doing it 6000 times?
Anyway, time to stop the equasion. I figured a way round this a while ago, and the way round it was to not use apache's directory listing and to use PHP to do it instead. Gives me lots of control too.
I.e. http://atomnet.co.uk/amiga/dir?game=Flashback
So I just replace Flashback with the game name, so what it does is checks the first letter of the game to find the first subfolder, and the game files are under the name that you type in anyway, and it works well. Had to double raw encode the game files as some of them contained + chars etc, but I wouldnt be typing those in manually anyway.
e.g. One of the files links -
Flashback%2520%25281992%2529%2528U.%2520S.%2520Gold%2529%255Bcr%2520Interpol%255D%255Bt%2520%252B2%2520Supplex%255D%2528Disk%25203%2520of%25204%2529.zip
Cheers anyway,
NS
Depends on how logically tall the tree is versus its logical width. How effective this is(how much subcategorizing by file storage tree structure the ellipses represent) is proportionate to height of data structure defined in folders versus indexed.
Will shut up now.... Happy you found a fix.
John Danielson.