Page 1 of 1

script to display list of files in a directory?

Posted: Mon Mar 10, 2003 8:47 am
by waskelton4
Hello Everyone,

I've been searching for a way to dynamically display a list of files contained in a directory but i'm not really sure what i should be searching for.

What i have is a form that users use to upload files to the webserver and I need to provide a way for certian people to view these files without worrying with ftp. Anybody out there know of a file or script that can be dropped in that directory that will, when accessed, read the current list of files and display them for downloading or viewing?

If there isn't such a thing, where would I begin if i wanted to write this?

Any help is greately appreciated.

Thanks
Will

Posted: Mon Mar 10, 2003 8:57 am
by twigletmac
Probably best to start here:
http://www.php.net/manual/en/ref.dir.php

Mac

Posted: Mon Mar 10, 2003 9:06 am
by waskelton4
Perfect..

Thanks Mac

Posted: Wed Mar 19, 2003 5:38 pm
by Gen-ik
As far as I know you can only read 'local' directories.. so trying to read the directory of someone elses website won't work.