Using the unlink() Function : unlink « File Directory « PHP






Using the unlink() Function

 
<?php

     $files = glob("/tmp/*.tmp");

     foreach($files as $val) {
               unlink($val);
     }
?>
  
  








Related examples in the same category

1.Deleting Files with unlink( )
2.Delete a file with the unlink() function.
3.Using file_exists, touch, and unlink together
4.You can remove an existing file with the unlink() function.
5.Deleting a file
6.Deleting files
7.Moving a file across filesystems