I'm making a script that creates a .html file in a folder called "users". What I want this little bit of code to do is to display only .html files, create a link to all of them and get rid of those 2 links to the parent directory. I've been screwing with the PHP manual and the code below for about 2 hours and I can't get it to this...any help would be greatly appreciated.
<?php
$handle=opendir('users');
echo "<b>Directory handle:</b> $handle <br>\n";
echo "<b>Files:</b> \n";
while (false !== ($file = readdir($handle))) {
echo "<a href='users/$file'>$file</a>\n";
}
closedir($handle);
?>