note 45470 modified in function.unlink by aidan
| From: | aidan@php.net | Date: | Thu, 09 Sep 2004 02:06:47 +0000 |
| Subject: | note 45470 modified in function.unlink by aidan | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-76263@lists.php.net to get a copy of this message | ||
To delete files using wildcards:
<?
function delfile($str)
{
foreach(glob($str) as $fn) {
unlink($fn);
}
}
?>
--was--
To delete files using wildcards:
<?
function delfile($str) {
foreach(glob($str) as $fn) {
@unlink($fn);
}
}
?>
http://php.net/manual/en/function.unlink.php