When we run below code its not working. unlink function shows file name but not delete that file from folder
<?php
$files = scandir("db-backup", 1);
$path = "settings/db-backup/";
echo '<table>';
foreach ($files as $key => $value)
{
if($value!='..' && $value!='.')
{
$r =$path.$value;
echo '<td>'.$value.'</td><td><input type="image" src="../../involve/images/icons/trash.png" value="Delete" onClick= "unlink('.$value.')"></td></tr>';
}
}
echo '</table>';
?>
onclick of button it call unlink function it show unlink(filename) but not delete the file from folder