I'm basically running on a linux server, with several directories and a good number of zip files per directory. What I'm wondering, basically, is there any way that I can get a web page to easily display the contents of that directory, and then have each file be a clickable link? Preferably without hours and hours of typing, if at all possible. Would be appreciated if anyone happened to know how to do this and could lend a bit of a hand with the code.
HTML Help
Moderator: Thanas
- General Zod
- Never Shuts Up
- Posts: 29211
- Joined: 2003-11-18 03:08pm
- Location: The Clearance Rack
- Contact:
HTML Help
So, I'm building a new site, and regrettably my html knowledge is somewhat spotty at best. I've got most of it covered, but searches aren't turning up much help so far, so I figured I'd see if anyone here happened to know how to solve this problem.
I'm basically running on a linux server, with several directories and a good number of zip files per directory. What I'm wondering, basically, is there any way that I can get a web page to easily display the contents of that directory, and then have each file be a clickable link? Preferably without hours and hours of typing, if at all possible. Would be appreciated if anyone happened to know how to do this and could lend a bit of a hand with the code.
I'm basically running on a linux server, with several directories and a good number of zip files per directory. What I'm wondering, basically, is there any way that I can get a web page to easily display the contents of that directory, and then have each file be a clickable link? Preferably without hours and hours of typing, if at all possible. Would be appreciated if anyone happened to know how to do this and could lend a bit of a hand with the code.
"It's you Americans. There's something about nipples you hate. If this were Germany, we'd be romping around naked on the stage here."
- Beowulf
- The Patrician
- Posts: 10621
- Joined: 2002-07-04 01:18am
- Location: 32ULV
- Pu-239
- Sith Marauder
- Posts: 4727
- Joined: 2002-10-21 08:44am
- Location: Fake Virginia
Have
somewhere in your apache config, or the easier way would be to have a file named .htaccess in the folder you want to have the files listed and have this as it's contents:
However, you have to have allowoverrides enabled in your apache config (which should be done for you if you are using shared hosting).
Code: Select all
<Directory [your directory here]>
Options +Indexes
</Directory>
Code: Select all
Options +Indexes
ah.....the path to happiness is revision of dreams and not fulfillment... -SWPIGWANG
Sufficient Googling is indistinguishable from knowledge -somebody
Anything worth the cost of a missile, which can be located on the battlefield, will be shot at with missiles. If the US military is involved, then things, which are not worth the cost if a missile will also be shot at with missiles. -Sea Skimmer
George Bush makes freedom sound like a giant robot that breaks down a lot. -Darth Raptor
- CDS
- Padawan Learner
- Posts: 301
- Joined: 2004-12-15 03:55pm
- Location: Lancaster University, UK
- Contact:
I think the original poster is after a directory listing that is inline to the webpage?
In which case, there may be a php script out there to do it - I've never needed to do it myself so don't know.
In which case, there may be a php script out there to do it - I've never needed to do it myself so don't know.

"Only two things are infinite, the universe and human stupidity, and I'm not sure about the former." --Albert Einstein
nimoll.co.uk technology website | N forums | Nimoll web design and hosting | Macguide