<?php echo "<html> <head><title>Файлменеджер</title></head> <body> <h1>Оглавление каталога</h1><p> <form action='edit.php' method='post'>\n"; if ($handle = opendir('.')) { while (false !== ($file = readdir($handle))) { if ($file != "." && $file != "..") { if (is_dir($file)) echo $file." (каталог)<br>\n"; if (is_file($file)) echo "<input type=radio name=file value=".$file.">".$file." (файл,размер: ".filesize($file).")<br>\n"; } } closedir($handle); } echo "<input type=submit name=edit value=edit> </form> </body> </html>"; ?>