![]() |
Home My Faqts Contributors About Help |
| Entry | Add Entry Alert - Edit this Entry |
Apr 26th, 2001 20:33
This is a small function I used in a recent project, hope it might be
useful.
function list_files($where)
{
if(is_dir($where))
{
$thisdir = dir($where);
while($entry=$thisdir->read())
{
if(($entry!='.')&&($entry!='..'))
{
$result.= "<a href=$where/
$entry>$entry</a><br>'";
}
}
}
return $result;
}
You can probably make it recursive, but I didn't have (or see) the need
to...
© 1999-2004 Synop Pty Ltd