PHP Scandir Function With HTML Form (Checkboxes)
I have a directory that contains various files, .txt, .xls, .pdf, etc I would like to be able to make a PHP script that uses the scandir function to fetch the filenames of every fi
Solution 1:
$files = scandir("./");
foreach ($files as $filename)
echo "<input type=\"checkbox\" name="files[]" value="{$filename}" /> {$filename}";
Post a Comment for "PHP Scandir Function With HTML Form (Checkboxes)"