Automatically List Directory Contents

Mr. Swillis

New Member
Hello,

I'm working on a web site that has a page that will contain a list of reports that will be uploaded daily. Since we will have constant updating of the directory contents, I am looking for a way to have the page dynamically update itself with links to the new files that are uploaded.

For example, say I have a directory off of root called "reports". In this directory I have report1.pdf - report5.pdf. I will have a "reports.htm" file that will contain links to these five reports. Tomorrow, a user will upload report6.pdf - report10.pdf. I would like the reports.htm page to automatically add links to these new reports. There will also be cases where reports will be removed and I would want the links to these to be removed as well.

If anyone knows a good way to script this, it would be greatly appreciated.

Thanks!

Swill
 

jnjc

New Member
Hello,

I'm working on a web site that has a page that will contain a list of reports that will be uploaded daily. Since we will have constant updating of the directory contents, I am looking for a way to have the page dynamically update itself with links to the new files that are uploaded.

For example, say I have a directory off of root called "reports". In this directory I have report1.pdf - report5.pdf. I will have a "reports.htm" file that will contain links to these five reports. Tomorrow, a user will upload report6.pdf - report10.pdf. I would like the reports.htm page to automatically add links to these new reports. There will also be cases where reports will be removed and I would want the links to these to be removed as well.

If anyone knows a good way to script this, it would be greatly appreciated.

Thanks!

Swill


You'll need to supply more info. what are you using to buld the site ? You'll need some sort of server-side scripting to get a directory listing (php is usually the most common).
 
Top