<?php
$p = 1;
if ($handle = opendir('./kelo/')) {
        while (false !== ($entry = readdir($handle))) {
            if ($entry != "." && $entry != "..") {
                //echo "$entry\n";
		$p++;
            }
        }
        closedir($handle);
   }
$p++;

$ourFileName = "a".$p.".txt";
$ourFileHandle = fopen($ourFileName, 'w') or die("Nemozem pripocitat o jedna viac, sorry");
fclose($ourFileHandle);
?>

