Heres the code for the deletion of the file, it is passed as a variable from the browser:
$delete = $_GET['delete'];
$directory = "/home/mao/input/files";
$handle = opendir($directory);
if(isset($delete))
{
while(!unlink("$directory/$delete"));
}
closedir($handle);
And to restate problem for clarity, if $delete variable has a ' in it then the php, of course, dumps an error. And seeing how the variable name has to stay the same to delete the file, I need a different solution. The link in which this php is being used has sensitive information...I might be able to create a dumby if it is needed though.