Revision 1220
Added by LordDarkman almost 16 years ago
| functions.php | ||
|---|---|---|
| 48 | 48 |
} |
| 49 | 49 |
|
| 50 | 50 |
// Empty the folder |
| 51 |
if (is_dir($directory)) {
|
|
| 51 | 52 |
$dir = dir($directory); |
| 52 | 53 |
while (false !== $entry = $dir->read()) {
|
| 53 | 54 |
// Skip pointers |
| ... | ... | |
| 66 | 67 |
// Now delete the folder |
| 67 | 68 |
$dir->close(); |
| 68 | 69 |
return rmdir($directory); |
| 70 |
} |
|
| 69 | 71 |
} |
| 70 | 72 |
|
| 71 | 73 |
// Function to open a directory and add to a dir list |
Also available in: Unified diff
Ticket #896: Bugfix in framework/functions.php > added test is_dir to function rm_full_dir