i want to have a bunch of files in a directory and use a loop function to number them. but i dont know how to do this, since i'm still a beginner at php. can anyone help me out? thanks
<?php $handle=opendir ('.'); while ($file = readdir ($handle)) { $i++; if ($file != "." && $file != "..") { print "File#: $i / $file<BR>\n"; } } closedir($handle); ?>
More informations about file handling: http://www.php3.de/manual/en/ref.filesystem.php