Simple question – simple answer:
How do I delete all files in a directory with PHP?
$files = glob('/path/to/directory/*.*'); foreach($files as $file) unlink($file);
Simple question – simple answer:
How do I delete all files in a directory with PHP?
$files = glob('/path/to/directory/*.*'); foreach($files as $file) unlink($file);
Comments 1
Pingback: PHP – Delete files by pattern | Freelancer Martin Zeller - php asp.net java c# .net c++ xhtml seo magento zend framework coremedia dotnetnuke telerik