<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns = 'http://www.w3.org/1999/xhtml' dir = "rtl">

<html>

<header><title>My Files</title>

<style>

.files{font:11px arial;}
a:link {color:#555555; text-decoration:none;}
a:visited {color: #555555; text-decoration:none;}
a:hover {color: #af3131;}
a:active {color: #af3131; text-decoration:none;}

</style>

</header>

<?php

$path='./files';// תיקיית הקבצים
$handle=opendir($path);

while (($file = readdir($handle))!==false) {
	echo "<a href = \"files/$file\"><span class = \"files\" >$file</span></a><br />";
}
closedir($handle);

?>

</html>