Argh
letat mig tokig i phpmanual, finns det nåt sätt att lista innehållet i en mapp???
------------------
lazy by nature
You can run, and you can hide, and I wont even look for ya
2 svar · 383 visningar · startad av JoakimE
Argh
letat mig tokig i phpmanual, finns det nåt sätt att lista innehållet i en mapp???
------------------
lazy by nature
You can run, and you can hide, and I wont even look for ya
<?
$handle = opendir("."); //
while ($file = readdir($handle))
$filelist[] = $file;
sort($filelist);
closedir($handle);
for($i=0; $i<count($filelist); $i++)
echo "$filelist[$i]\n";
// för att kolla om det är en mapp, använd is_dir(), för fil använd is_file().
?>
------------------
BABBA
/ * It's not a lie if you believe it * /
http://www.webbkontor.com
[Redigerat av BABBA den 26 nov 2000]